Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- factors n = [x | x <- [1..n], n `mod` x == 0];
- is_prime n = factors n == [1, n]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement