rewrite for greedy
TrappingRainWater.cpp