[Haskell-cafe] How to get an variable or its value?

Daniel Fischer daniel.is.fischer at web.de
Fri May 6 10:05:22 EDT 2005


Am Freitag, 6. Mai 2005 15:48 schrieb Michael Onofruk:
> Hi!
> From this "monster" [([Int],Char)] I need to get Char
> variable. How do I do this? Or in general - how does
> this works in Haskell?
>
Which Char do you want?

map snd 

will give you [Char]. If you want one Char (depending on the accompanying 
[Int]), you might want something like lookup or find from Data.List

Cheers,
Daniel

> Cheers, M.
>
>
>
> Yahoo! Mail
> Stay connected, organized, and protected. Take the tour:
> http://tour.mail.yahoo.com/mailtour.html
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe



More information about the Haskell-Cafe mailing list