First Duplicate Value Leetcode Problems On Loops