Lean
4
Language
Tactics
Playground
Academy
Problems
Pricing
Search
⌘K
Problems
All problems
Problems
Leaderboard
Ranking
My progress
Progress
Courses →
Get the
Pass · €14
Problems
/
41
41. Trapping rain water
Hard
Program
Academy Pass
How much rain water a row of bars holds after it rains.
lists
prefix scans
performance
Opening the problem…
Similar problems
35. Merge intervals
Medium
55. Majority element
Medium
24. Best time to buy and sell
Easy
30. Edit distance
Hard
← 40. Longest increasing subsequence
42. Infinitely many primes →