Thanx for the help
I tried Sayed's code first like this.
But i got the following output:
Current int: 2
Current int: 4
Current int: 5
Current int: 6
Current int: 8
Current int: 9
Current int: 11
Current int: 15
Current int: 16
Current int: 17
Current int: 18
Current int: 20
There are no duplicates, but there are also missing numbers which is not what i need.
And im not sure if they should be, but they are sorted, even though i need to kinda do this task later on anyway.
Next i tried marc's code.
It seems to work perfectly for what i need, but just 2 things i dont understand.
1. I dont fully understand the flow of how it works (im still a beginner at
java)
2. Why do you put: randomNum[choice] = randomNum[limit]; near the very end?
Before this when it prints out the number, its random with no duplicates, but after it goes over it with the value of limit, im confused there.
But thank you very much for the help
My next tasks for the card will be to:-
Sort the random 20 numbers of 1-90 into blocks of 1-10, 11-20 etc.
Then add each block into a 2 dimensional array of a column for each block with a grid of 9x4.
Then add in the 16 blank spaces.
Then map out a print with the correct values in the correct places.
I hope i can do all this stuff on my own *fingers crossed*