Created
January 30, 2015 16:15
-
-
Save yutopp/731c1431c3d46ec9842d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let double n = n *. 2.0 ;; | |
print_newline() ;; | |
let rec f n = if n == 0 then () else f (n - 1); print_int n; print_newline();; | |
f 10;; | |
print_float (double 3.14);; | |
print_newline();; | |
let rec sum n = if n == 0 then 0 else n + sum (n-1);; | |
print_int (sum 10);; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment