write a python program to replace even numbers with its double and odd numbers with its triple in a list.
Answers
# Python program to replace even numbers with its double and odd number with its triple in a list of number
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from user
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:"))
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1)
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1:
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0:
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0: i=int(i*2)
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0: i=int(i*2) list2. append (i)
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0: i=int(i*2) list2. append (i) else:
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0: i=int(i*2) list2. append (i) else: i=int (i*3)
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0: i=int(i*2) list2. append (i) else: i=int (i*3) list2. append(i)
# Python program to replace even numbers with its double and odd number with its triple in a list of number# entering a list from userlist1=eval(input("Enter a list of numbers:")) print("Original list :", list1) list2=[ ] # creating an empty list#According to the question for i in list1: if i℅2==0: i=int(i*2) list2. append (i) else: i=int (i*3) list2. append(i) print("New list:", list2)