



























Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




























CIS120 6-‐character device ID
In what language do you have the most significant programming experience?
imperaWve programming is about doing
value-‐oriented programming is about being
open Assert let attendees (price:int) :int = (- 15 * price) / 10 + 870 let test () : bool = attendees 500 = 120 ;; run_test "attendees at 5.00" test let x = attendees 500 ;; print_int x ;; print_endline "end of demo" module import commands funcWon declaraWons let declaraWons
let pi = 3. let seconds_per_day = 60 * 60 * 24! *We someWmes call these idenWfiers variables , but the terminology is a bit confusing because in languages like Java and C a variable is something that can be modified over the course of a program. In OCaml, like in mathemaWcs, once a variable’s value is determined, it can never be modified… As a reminder of this difference, for the purposes of OCaml we’ll try to use the word “idenWfier” when talking about the name bound by a let.