@@ -0,0 +1,657 @@
+package com.avalontm.leetcode._217ContainsDuplicate;%0A%0Aimport java.util.HashSet;%0A%0A/**%0A * 217.Contains Duplicate%0A * Given an array of integers, find if the array contains any duplicates.%0A * Your function should return true if any value appears at least twice in the array,%0A * and it should return false if every element is distinct.%0A * %3Cp/%3E%0A * Created by jiang_s on 2015/7/17.%0A */%0Apublic class Solution %7B%0A    public boolean containsDuplicate(int%5B%5D nums) %7B%0A        HashSet%3CInteger%3E exists = new HashSet();%0A        for (int i = 0; i %3C nums.length; i++) %7B%0A            if(!exists.add(nums%5Bi%5D))%0A                return true;%0A        %7D%0A        return false;%0A    %7D%0A%7D%0A

217.Contains Duplicate