█████████ ████ ███░░░░░███ ░░███ ███ ░░░ ██████ ███████ ██████ ██████ ░███ ███░░███ ███░░███ ███░░███ ███░░███ ░███ ░███ ░███░███ ░███ ░███████ ░███ ░███ ░░███ ███░███ ░███░███ ░███ ░███░░░ ░███ ░███ ░░█████████ ░░██████ ░░████████░░██████ ░░██████ ░░░░░░░░░ ░░░░░░ ░░░░░░░░ ░░░░░░ ░░░░░░

Envío 3586

Problema 0x9d - ¿Está ordenado?

  • Autor: jmarrietar
  • Fecha: 2021-03-28 23:04:19 UTC (Hace más de 3 años)
Caso # Resultado Tiempo Memoria
#1
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.02 s 3 KBi
#2
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.023 s 3 KBi
#3
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.027 s 7 KBi
#4
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.026 s 6 KBi
#5
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.016 s 3 KBi
#6
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.015 s 3 KBi
#7
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.016 s 3 KBi
#8
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.016 s 3 KBi
#9
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.025 s 3 KBi
#10
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.026 s 5 KBi
#11
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.037 s 5 KBi
#12
Error en tiempo de ejecución (NZEC)
Exited with error status 1
Traceback (most recent call last):
  File "script.py", line 10, in <module>
    print(ordenado(numbers, length))
  File "script.py", line 5, in ordenado
    for i in range(0, length-1):
TypeError: unsupported operand type(s) for -: 'list' and 'int'
0.016 s 3 KBi
Puntos totales: 0 / 100

Código

length = [int(x) for x in input().split()]
numbers = [int(x) for x in input().split()]

def ordenado(numbers, length):
 for i in range(0, length-1):
  if numbers[i]>numbers[i+1]:
   return "Desordenado"
 return "Ordenado"

print(ordenado(numbers, length))