Two Pointer Approach Leetcode Playground Java