mnagaoormeeran
mnagaoormeeran mnagaoormeeran
  • 18-12-2020
  • Computers and Technology
contestada

X= [12,67,89,34,56,90,67]

Write a python program to bring the following output by using the given X.

Output:

[12,67,89,34,100,56,90,67]

​

Respuesta :

PlayersZero PlayersZero
  • 18-12-2020

Answer:

X = [12, 67, 89, 34, 56, 90, 67]

for i in range (len(X)):

   if (X[i] == 34):

       print(X[i])

       print("100")

   else:

       print(X[i])

Explanation:

Kind of a ugly hack because I'm not all too familiar with python, but it gets the job done :^)

Answer Link

Otras preguntas

channel name:- being bombastic like, comment and subscribe​
the average height of a class of 18 students is 105cm. After the arrival of 7 new students the average decreases by 5cm. Find sum of the heights of all the stud
Use the range rule of thumb to identify the values that are significantly​ low, the values that are signficantly​ high, and the values that are neither signific
Which of the following founding beliefs was inspired by salutary neglect?A.free market economyB.consent of the governedC.freedom of speechD.unalienable rightsRe
which of the following is most likely the next step in the series ?
Kakalasan Kasukdulan Suliranin Wakas Cupid at Psyche Simula
what is the preterite and imperfect of “luis es mi amigo”
tình hình ô nhiễm của vi sinh vật hiếu khí trong và ngoài nước
essay sanaysay o salaysay
What is the relationship between angle 1 and 2?