diff --git a/medium/11 Container with most Water/solution.py b/medium/11 Container with most Water/solution.py index 67955fb..bb011ae 100644 --- a/medium/11 Container with most Water/solution.py +++ b/medium/11 Container with most Water/solution.py @@ -4,10 +4,10 @@ class Solution: r = len(height) - 1 max_area = (r-l) * min(height[l], height[r]) - while (r-l > 2): - if (height[l] <= height[r]): + while r-l > 2: + if height[l] <= height[r]: l += 1 else: r -= 1 max_area = max(max_area, (r-l) * min(height[l], height[r])) - return max_area \ No newline at end of file + return max_area