Python print list after removing the ODD numbers

Here, we are going to actualize a python program that will print the list in the wake of expelling ODD numbers.

Given a list, and we need to print the list in the wake of expelling the ODD numbers in Python.


    list = [11, 22, 33, 44, 55]

    list after removing ODD numbers
    list = [22, 44]


  • Navigate each number in the list by utilizing for…in circle.
  • Check the condition for example checks number is separable by 2 or not – to check ODD, the number must not be distinguishable by 2.
  • On the off chance that number isn’t distinct by 2 for example ODD number from the list, use list.remove() strategy.


# list with EVEN and ODD number
list = [11, 22, 33, 44, 55]

# print original list
print "Original list:"
print list

# loop to traverse each element in the list
# and, remove elements
# which are ODD (not divisible by 2)
for i  in list:
	if(i%2 != 0):

# print list after removing ODD elements
print "list after removing ODD numbers:"
print list


    Original list:
    [11, 22, 33, 44, 55]
    list after removing ODD numbers:
    [22, 44]

2 thoughts on “Python print list after removing the ODD numbers”

  1. Hi , I am sabaresan D from chennai Ece Department in college , I am also very interest python to do code but i don’t know where i going to start ..can you help me pls?. this is my mail id..


Leave a Comment

error: Alert: Content is protected!!