Archive
Archive for July 16, 2019
Python: Smallest Multiple
July 16, 2019
Leave a comment
Python: Smallest multiple
Problem 5 @ projecteuler
Completed on: Thu, 4 Jul 2019, 22:30
Here I am quoting form ProjectEuler site:”
2520 is the smallest number that can be divided by each of the numbers from 1 to 10 without any remainder. What is the smallest positive number that is evenly divisible by all of the numbers from 1 to 20?”
So to solve this simple task all we need to loop through numbers and divide it by a list of (1,20) if yes return True otherwise return False and got to another number.
and so we done..
![]() |
The Code:
codes here
![]() |
Categories: Problem, Projects/Experiments, Python
ahradwano.com, Ali, Code, doha, Problem, ProjectEuler, Python, Qatar, radwani