Last active
August 29, 2015 14:22
-
-
Save jhedev/5a4e2b8b97bff98c264c to your computer and use it in GitHub Desktop.
multiples
This file contains 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
module Main where | |
import Data.List | |
mult :: Int | |
mult = sum $ nub [i*x | x <- [3,5], i <- [1..(1000 -1)`div` x]] | |
main :: IO () | |
main = print mult |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment