MATH 114 Midterm: MATH 114 UPenn 114Fall 08 Exam

16 views21 pages
31 Jan 2019
School
Department
Course
Professor

Document Summary

List the four steps of the design process (or recipe ) that we used throughout the semester: understand the problem (and how the concepts relate to each other, de ne the interface, write tests, implement (i. e. , write the code) 2: true or false (10 points) a. b. c. d. e. In ocaml, if x is a variable of any type, some x == some x will always return true. In ocaml, data structures such as records and datatypes are immutable by default. Binary search trees can only be implemented in ocaml. Every mutable reference in ocaml could be null. In java, a static method dispatch c. m() implicitly pushes the this reference onto the stack. In java, if an exception is thrown but not caught, it immediately terminates the program. In java, any method that could throw a nullpointerexception must include the clause throws nullpointerexception in the method header.