Caso # | Resultado | Tiempo | Memoria |
---|---|---|---|
#1 |
Correcto
|
0.093 s | 9 KBi |
#2 |
Correcto
|
0.093 s | 9 KBi |
#3 |
Correcto
|
0.099 s | 9 KBi |
#4 |
Correcto
|
0.099 s | 9 KBi |
#5 |
Correcto
|
0.078 s | 9 KBi |
#6 |
Correcto
|
0.089 s | 9 KBi |
#7 |
Correcto
|
0.103 s | 9 KBi |
#8 |
Correcto
|
0.105 s | 9 KBi |
#9 |
Correcto
|
0.097 s | 9 KBi |
#10 |
Correcto
|
0.099 s | 9 KBi |
#11 |
Correcto
|
0.099 s | 9 KBi |
#12 |
Correcto
|
0.097 s | 9 KBi |
n = gets.to_i a = gets.split.map(&:to_i) def solve(array) min_number = -1000000001 last_number = min_number array.each do |numb| if last_number >numb return "Desordenado" end last_number = numb end return "Ordenado" end puts(solve(a))