-- untested and won't work on an infinite list
last :: [a] -> a
last = head . reverse

-deech

On Fri, Dec 31, 2010 at 2:39 PM, Aaron Gray <aaronngray.li...@gmail.com> wrote:
> Is there an easy Haskell function that gets the last Char of a [Char] or
> String ?
> Many thanks in advance,
> Aaron
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
>

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to