FileDocCategorySizeDatePackage
FindDups.javaAPI DocExample342Tue Dec 12 18:59:42 GMT 2000None

FindDups

public class FindDups extends Object

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] args)

        Set s = new HashSet();
        for (int i=0; i<args.length; i++)
            if (!s.add(args[i]))
                System.out.println("Duplicate detected: "+args[i]);

        System.out.println(s.size()+" distinct words detected: "+s);