Hi Fabian, * Fabian Meier <[EMAIL PROTECTED]> [2002-11-22 14:55 +0100]: > The file versuch.lhs (attachment) consists of a function gc2. If you > try gc2 25 15, hugs produces a run time error.
> gc2 ist defined as:
> > gc2::Int->Int->Int
> > gc2 a1 a2 = gc2 a2 (mod a1 a2)
> > gc2 a2 0 = a2
You have to change the last two lines, and learn how pattern matching in
Haskell works ;o)
> gc2::Int->Int->Int
> gc2 a2 0 = a2
> gc2 a1 a2 = gc2 a2 (mod a1 a2)
Regards,
Olli
--
{- IST & IIS _ INF _ UniBwM :: [EMAIL PROTECTED] -}
{- Tele-Consulting GmbH :: [EMAIL PROTECTED] -}
{- FreeBSD Commmitter :: [EMAIL PROTECTED] -}
msg02382/pgp00000.pgp
Description: PGP signature
