7 Jun
2009
7 Jun
'09
10:17 p.m.
Hi Andrew, Andrew Savige wrote:
Noticing this, you can replace the 205558`mod`(ord c)`mod`7 magic formula with a function that returns a string index (index() in Perl and Python). I am sometimes overwhelmed by the quantity and richness of all the functions in the GHC Haskell libraries.
Have you tried hoogle? http://haskell.org/hoogle/?hoogle=String+-%3E+Maybe+Int This suggests Data.List.elemIndex. Tillmann