Markynsai Markynsai
  • 02-03-2021
  • Computers and Technology
contestada

Need help with a program to search to sort elements in an array.(increasing or decreasing order)

Respuesta :

60002135330 60002135330
  • 02-03-2021

This is for Python

numbers = [7, 3, 6, 9, 0]

print(numbers.sort())

Output: [0, 3, 6, 7, 9]

numbers = [7, 3, 6, 9, 0]

print(numbers.sort(reverse = True))

Output: [9, 7, 6, 3, 0]

Answer Link

Otras preguntas

A nurse is caring for a client who is experiencing major depression. what feeling should the nurse anticipate that the client will likely have difficulty expres
8x what is x? Please
_____ form a part of the microenvironment that influences retail management decisions. competitors technologies politics
Which research question would work best to narrow the following topic for a five-paragraph paper (300 words)? the use of graphic novels in the classroom a-What
A 20-month-old toddler has been treated with permethrin for scabies. the toddler's mother asks, "is this medication working? my child is still itching." which r
what is the factorization of the trinomial below 3x2+27x+60
Is the correct answer to this problem one solution because 19x=-19?? Or am I wrong??
-k/7=-4 i dont know how to do one step equations
How did the peace made after world war 2 differ from world war 1?
. Select the sentence which correctly uses the verb Avoir: (1 point) Ils a des chaussures vertes. Ils as des chaussons blancs. Ils ont des pulls bleus. Ils ai d