+ 1
Hi can you help me about java
I want to create an spelling contest which the name of the highest score will be print not the score using bubble sort
5 Respuestas
+ 1
https://code.sololearn.com/c9f65g37PSIr/?ref=app
I editted your code now it works.
But you code works only if 3 or more players participate.
If user entered only 1 player or 2 players' data, we have to design the code for these cases also.I've not done it but it can be done.
If you want me to do it, you can tell.
0
Here is my code
0
I want to print sir the name who will be the first second and third sir
0
.store name, score to class Student
.store best Students as objects to array winners[3]
if you have to avoid sorting
.add students by addByOrder(Student st) {
if (position is null)
add student
else
if (position has a lower score){
shift rest of array to the right
add student at position
}}