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

Look at the diagram. When this process happens in human cells, how many chromosomes will there be in cell F? Enter your answer as a number
Someone please help me I’m literally struggling
Why is the society important for us? D​
−3x−6+(−1) need answer pls
During World War II, how did Mahatma Gandhi, the Indian leader, characterize the United States and Great Britain?
the area of the room is 234 square feet. the length of the room is 18 feet. what is the width, in feet, of the room?
A government is trying to promote industrialization. It is concerning because the country has few banks able to finance expensive industrial enterprises. It rea
how do you calculate voltage drop
1/f = 1/d + 1/d' How do I find d'?
r(x)=2[tex]r(x)=2[/tex]