Leetcode 42 – Trapping Rain Water | Two Pointer
Problem Description: Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it can trap after raining. Example 1 : Example 2: Constraints: Problem Link :Trapping Rain Water – LeetCode Solution(s): Approach 1: Java Code: Complexity: Approach 2: Using Two Pointers Java Code: Complexity: