
2 Dec
2006
2 Dec
'06
7:20 a.m.
Hello,all My intention is to generate 50 random coordinates like (x,y). myrand :: Int myrand = randomRIO(1::Int, 100) rf=[(myrand, myrand) | a <- [1..50]] My short program is like this. However, GHCI say that the return type of randomRIO is IO a while the function defined by me is Int. Since I only need a integral type as my cooridinate, could you tell me how to fix this? Hank -- View this message in context: http://www.nabble.com/Generate-50-random-coordinates-tf2742242.html#a7651116 Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.