tweak ml code/instructions
authorJim Pryor <profjim@jimpryor.net>
Mon, 20 Sep 2010 16:18:36 +0000 (12:18 -0400)
committerJim Pryor <profjim@jimpryor.net>
Mon, 20 Sep 2010 16:18:36 +0000 (12:18 -0400)
Signed-off-by: Jim Pryor <profjim@jimpryor.net>
using_the_programming_languages.mdwn

index 5dfcb36..ae40499 100644 (file)
@@ -43,16 +43,16 @@ know much OCaml yet to use it. Using it looks like this:
                let add = << fun m n -> n $succ$ m >>;;
                (* or *)
                let add = << fun m n -> fun s z -> m s (n s z) >>;;
                let add = << fun m n -> n $succ$ m >>;;
                (* or *)
                let add = << fun m n -> fun s z -> m s (n s z) >>;;
-
+               
                (* now use:
                        pp FORMULA                              to print a formula, unreduced
                        pn FORMULA                              to print the normal form of a formula (when possible)
                        pi FORMULA                              to print the integer which FORMULA is a Church numeral for (when possible)
                (* now use:
                        pp FORMULA                              to print a formula, unreduced
                        pn FORMULA                              to print the normal form of a formula (when possible)
                        pi FORMULA                              to print the integer which FORMULA is a Church numeral for (when possible)
-                         
+               
                        alpha_eq FORM1 FORM2    are FORM1 and FORM2 syntactically equivalent (up to alpha-conversion)?
                                                                        this does not do reductions on the formulae
                *)
                        alpha_eq FORM1 FORM2    are FORM1 and FORM2 syntactically equivalent (up to alpha-conversion)?
                                                                        this does not do reductions on the formulae
                *)
-                 
+               
                pi << $add$ $one$ $two$ >>;;
                - : int = 3
 
                pi << $add$ $one$ $two$ >>;;
                - : int = 3