Java Array And String Questions Leetcode Two Sum