130k views
1 vote
PLEASE HELP MEEEEEEE :(

I have a piece of code that keeps track of the leaderboard of a game then it will sort the scores in order and print them onto the screen along with the names.
Unfortunately I don't want the whole file printing, just the top 5.
what shall id do.?

I have attatched the code.
Thanks.​

PLEASE HELP MEEEEEEE :( I have a piece of code that keeps track of the leaderboard-example-1

2 Answers

4 votes

Answer: If you want to use a for loop then you should make it so that it does variable I and then it takes the array and you do Topscorers[I] and then it will do the first 5

Step-by-step explanation:

User Bacardi
by
7.8k points
4 votes

Answer:

Ctrl A and then Ctrl C

Step-by-step explanation:

First click Ctrl A then click on the parts that you need to copy then click Ctrl C

User Witoldio
by
7.4k points