Created
August 29, 2023 09:33
-
-
Save codeperfectplus/cab4710130fa0c152600b1262401d8e0 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def multiples(n): | |
| sum = 0 | |
| for i in range(n): | |
| if(i%3==0) or (i%5==0): | |
| sum += i | |
| return sum | |
| print(multiples(1000)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment