Hi there,

The best way I can explain what I'd like to do is show an example, so here goes:

same :: a -> a -> Bool
same x x = True
same _ _ = False

Is there any way to do this in Haskell? The actual reason I'd like to do this is something slightly more complicated. I want to match against a list of elements, like so:

foo [x,x,x] = ...

Thanks for any help.

- Alex