http://www.perlmonks.org?node_id=369227


in reply to Re^3: RFC: A Perlesque Introduction to Haskell, Part One (draft)
in thread RFC: A Perlesque Introduction to Haskell, Part One (DRAFT)

Haskel goes a little further, though, because it supports function-dispatch by pattern matching...

My mind has been full of Perl6 lately ... so bear with me ...

multi sub factorial (Any where {$^n==0} $n) { 1 } multi sub factorial ($n) { $n * factorial $n-1 }

... which of course will recurse infinitely when given factorial 0.5 or factorial -1 ...

ObTopic: How do the Haskell examples handle those cases?

print "Just another Perl ${\(trickster and hacker)},"
The Sidhekin proves Sidhe did it!