Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- func euler001() -> Int {
- var total = 0
- for num in 0..<1000 {
- if num % 3 == 0 || num % 5 == 0 {
- total += num
- }
- }
- return total
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement