diff --git a/baby.hs b/baby.hs new file mode 100644 index 0000000..8c03644 --- /dev/null +++ b/baby.hs @@ -0,0 +1,10 @@ +-- baby.hs +-- Eryn Wells + +-- Simple functions +doubleMe x = x + x +doubleUs x y = doubleMe x + doubleMe y +boomBangs xs = [if x < 10 then "BOOM!" else "BANG!" | x <- xs, odd x] + +-- List comprehensions +triangles = [(a,b,c) | c <- [1..10], b <- [1..10], a <- [1..10]]