Answer to Question #310293 in Python for xxx

Question #310293

Question 4


Answer:


Question 4 Output

array([8 10 12 14 16 18 20])


Question 5


print("Original array:")

Answer:


print(x)

>>>[12 13 14 15 16 17 18 19]

print("Reverse array:")

Answer:


>>>array([19, 18, 17, 16, 15, 14, 13, 12])


Question 6


x = [11, 12, 13]

print("Original array:")

print(x)


Answer:


print("After append values to the end of the array:")

print(x)


Question 6 Output

Original array:

[11,12,13]

After append values to the end of the array:              

[21 22 23 24 31 32 33 34]



1
Expert's answer
2022-03-14T08:37:18-0400
#Question 4
x = [8, 10, 12, 14, 16, 18, 20]
print("Q.4: Output: ",x)




#Question 5
x = [19, 18, 17, 16, 15, 14, 13, 12]
print("\nQ.5: Original array: ",x)
x = sorted(x)#,reverse=True)
print("Reverse array: ",x)


#Question 6
x = list([11, 12, 13])
print("\nQ.6: Original array: ",x)
x = x+list([21, 22, 23, 24, 31, 32, 33, 34])
print("After append values to the end of the array: ",x)

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS