[Haskell-cafe] weired

2005-07-16 Thread wenduan
The following function which converts a number represents a sum of money in pence didn't work as expected and the result didn't make any sense to me: penceToString :: Price - String penceToString p = let str = show p len = length str in if len ==1 then 0.0 ++ str else

Re: [Haskell-cafe] weired

2005-07-16 Thread Einar Karttunen
wenduan [EMAIL PROTECTED] writes: The following function which converts a number represents a sum of money in pence didn't work as expected and the result didn't make any sense to me: penceToString :: Price - String penceToString p = let str = show p len = length str in