0

Can I get help to make Scanner work with bubbleSort?

I need help with Scanner for bubbleSort of int[]. https://code.sololearn.com/cyXN2S7817n0/?ref=app

16th Jun 2018, 7:30 AM
LottoMan
3 Respuestas
+ 2
Fix a couple simple things https://code.sololearn.com/cDGLs1R3Id2o
16th Jun 2018, 7:18 PM
John Wells
John Wells - avatar
+ 2
You only get output, when values get swapped. Otherwise, it uses break to exit the outer loop without any output. Move lines 28 & 29 down to follow line 35 to always get output.
18th Jun 2018, 7:35 PM
John Wells
John Wells - avatar
+ 1
My bubbleSort program does not display "Bubble Sort: " or value of inputs when all the inputs are all equal. What is cause of this skipped output of "BubbleSort : " and the values of the inputs? https://code.sololearn.com/cyXN2S7817n0/?ref=app
18th Jun 2018, 6:50 PM
LottoMan