I need to write a program for someone to enter 5 numbers from 10 to 100 and eliminate duplicates. after entering 5 valid numbers, i get error,
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 5
at DuplicateElimination.main(DuplicateElimination.java:23)

I need to write a program for someone to enter 5 numbers from 10 to 100 and eliminate duplicates. after entering 5 valid numbers, i get error,
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 5
at DuplicateElimination.main(DuplicateElimination.java:23)

I figured it out,
i was using counter out of range.