+ 2
Tell me how to sort number without using collection
write a program to sort numbers without using collection
3 Respuestas
+ 3
One can use any sorting algorithms (bubble sort, selection sort, insertion sort, quick sort, heap sort etc).
If you are sorting a list instead of an array, you can convert it to array for simplicity.
Below is the code for bubble sort----
https://code.sololearn.com/cg471Lvj860a/?ref=app
+ 2
@ Adi Pratama
sort() method is a part of Collections and we dont have to use it here.
0
Thanks