I used random function in my code however i dont know how could i prevent repetition.Also i read another questions about this subject but i dont want to use "Shuffle".
Thanks for all help and clues.
Set doesn't allow duplicates
Set set = new HashSet();
while (set.size() < 20) {
set.add(r.nextInt(100));
}