Half Line  |  O(1)  |  Rust
Complexity
Time complexity: O(1)

Space complexity: O(1)
Code
# Complexity
- Time complexity: $$O(1)$$
<!-- Add your time complexity here, e.g. $$O(n)$$ -->

- Space complexity: $$O(1)$$
<!-- Add your space complexity here, e.g. $$O(n)$$ -->

# Code
```rust []
impl Solution {
    pub fn max_containers(n: i32, w: i32, max_weight: i32) -> i32 {
        (n * n * w).min(max_weight) / w
    }
}
```
['Rust']