python-dev avatar

Python Program to Find Numbers Divisible by Another Number

python-dev

Published: 22 Mar 2020 › Updated: 22 Mar 2020Python Program to Find Numbers Divisible by Another Number

Python Program to Find Numbers Divisible by Another Number

# Take a list of numbers
my_list = [12, 65, 54, 39, 102, 339, 221,]

# use anonymous function to filter
result = list(filter(lambda x: (x % 13 == 0), my_list))

# display the result
print("Numbers divisible by 13 are",result)

Leave Python Program to Find Numbers Divisible by Another Number to:

Written by

Read more #python-dev posts


Best Posts From python-dev

We have not curated any of python-dev's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.

More Posts From python-dev