Given an elevation map, compute how much water it can trap after raining.
Sample Input:
[0,1,0,2,1,0,1,3,2,1,2,1]
Hints
Hint 1
Use two-pointer approach from both ends
Hint 2
Track max height from left and right
Hint 3
Water at each position is min(maxLeft, maxRight) - height[i]