Re: programation

Startseite

Nachricht beantworten
Autor: Tim Walker
Datum:  
To: guilde
Betreff: Re: programation
Merci pour le patch, mais je ne pouvais pas le compiler chez moi.
Quelqu'un a-t-il un version 'free' de garbageIn2garbageOut ?


;)

[EndOfThread!]

Manu Rouat wrote:
>
> Tim Walker wrote:
> >
> > smallProgram = TEXT
> > largeprogram = TEXT
> >
> > PROC tryItAndSee(smallProgram)
> > BEGIN
> >         UNTIL CORRECT
> >                 DO
> >                         WRITE(smallProgram)
> >                         TEST(smallProgram)
> >                 DONE
> >         RETURN HAPPY
> > END

> >
> > PROC happtTodoSomeMore(Program):BOOLEAN
> > FUN = 100
> > BEGIN
> >         UNTIL CORRECT
> >                 DO
> >                         WRITE(largeProgram)
> >                         TEST(largeProgram)
> >                         FUN = FUN - 1
> >                 DONE

> >
> >         IF FUN <= 10 THEN
> >                 RETURN FALSE
> >         ELSE
> >                 RETURN TRUE
> >         END IF
> > END

> >
> > MAIN Program()
> > BEGIN
> >
> >         tryItAndSee(smallProgram)

> >
> >         WHILE happyToDoSomeMore(largeProgram)= TRUE
> >                 CONTINUE
> >         ELSE
> >                 STOP
> > END

>
> Y'a un bug.... dans la grande tradition du logiciel libre, voici un patch:
>
> --- prog.orig   Fri Apr  2 19:36:39 1999
> +++ prog        Fri Apr  2 19:40:31 1999
> @@ -32,12 +32,24 @@
>  BEGIN
>         UNTIL CORRECT
>                 DO
> +                       GetDocumentation(void)
>                         WRITE(smallProgram)
>                         TEST(smallProgram)
>                 DONE
>         RETURN HAPPY
>  END

>
> +
> +PROC GetDocumentation(void)
> +BEGIN
> +       UNTIL UNDERSTOOD
> +               DO
> +                       READTHEFUCKINGMANUAL
> +                       READTHEFUCKINGMANUAL
> +                       READTHEFUCKINGMANUAL
> +               DONE
> +       RETURN
> +END

>
> PROC happtTodoSomeMore(Program):BOOLEAN
> FUN = 100
>
> manu


-- 
----------------------------------------------------------------------
Tim Walker                                             Hewlett-Packard
Tel:     (+33) 04.76.14.12.33          Telecom Infrastructure Division
Fax:     (+33) 04.76.14.14.88            38053 Grenoble Cedex 9 FRANCE


HamNet:   f4jhd@??? (44.151.38.17)
      f4jhd@???
----------------------------------------------------------------------