DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
<- And Let .. = Confusion
// description of your code here
module Main where import Random main = do -- Either of these work --rnum <- oneRandNum let rnum = oneRandNum -- But only let works here. Why? --numbers <- randArray let numbers = randArray -- Required for successful compilation. print "foo" oneRandNum :: IO Int oneRandNum = getStdRandom( randomR( 0, 9 ) ) randArray :: [IO Int] randArray = [oneRandNum]




