[Haskell-cafe] Examples of using STUArray + help with converting code

Ketil Malde ketil+haskell at ii.uib.no
Fri Oct 14 09:31:36 EDT 2005


Joel Reymont <joelr1 at gmail.com> writes:

> If I don't cast then how do I convert this code?

Uh, what is wrong with divMod?  

  *Main Data.Word> (10000000000::Word64) `divMod` (2^32)
  (2,1410065408)

> doubleToInts d = runST ( [...]

This will only give you a headache. :-)

-k
-- 
If I haven't seen further, it is by standing in the footprints of giants



More information about the Haskell-Cafe mailing list