Run Code  | Code Wall  | Users  | Misc  | Feedback  | About  | Login  | Theme  | Privacy 

H.W.5 ALL Solutions

Language: Editor: Layout:
+ ] Show input
Absolute running time: 0.26 sec, cpu time: 0.22 sec, memory peak: 6 Mb, absolute service time: 0,27 sec  
edit mode |  history  | discussion
Hello, world!
[100, 5, 105, 89, 8, 23, 1]
[1, 5, 8, 23, 89, 100, 105]
Max number:  93
After swap:  [26, 54, 31, 17, 77, 93]

Max number:  77
After swap:  [26, 54, 31, 17, 77, 93]

Max number:  54
After swap:  [26, 17, 31, 54, 77, 93]

Max number:  31
After swap:  [26, 17, 31, 54, 77, 93]

Max number:  26
After swap:  [17, 26, 31, 54, 77, 93]

[17, 26, 31, 54, 77, 93]
Max number:  41
After swap:  [9, 8, 30, 6, 0, 1, 40, 41]

Max number:  40
After swap:  [9, 8, 30, 6, 0, 1, 40, 41]

Max number:  30
After swap:  [9, 8, 1, 6, 0, 30, 40, 41]

Max number:  9
After swap:  [0, 8, 1, 6, 9, 30, 40, 41]

Max number:  8
After swap:  [0, 6, 1, 8, 9, 30, 40, 41]

Max number:  6
After swap:  [0, 1, 6, 8, 9, 30, 40, 41]

Max number:  1
After swap:  [0, 1, 6, 8, 9, 30, 40, 41]

r [0, 1, 6, 8, 9, 30, 40, 41]