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

solve by substition: y=3x+14 y=-4x
Hugo by the soccer ball for $15 plus 8.75 % tax.greg buys a football for $20 plus 8.75% tax . what is their total including tax
sino ang naging unang punong ministro ng india
Hospitals announce that there are not enough nurses available to keep them fully staffed. economically speaking, what does this announcement mean?
A successful basketball player has a height of 6 feet 88 ​inches, or 203203 cm. based on statistics from a data​ set, his height converts to the z score of 4.10
"individual differences" is a narrow category only used to describe the "big five" personality attributes.
What is the volume, in mL, of mercury, if it weighs 4.55 kg and has a density of 13.0g/mL?
what is the name of Canada's largest island
What is the solution for this system of equations y = x - 4 Y = -x + 6
During the time of president Andrew Jackson,which group in the United States gained suffrage