Discussion Section Notes for CS 131 (Spring'16, UCLA)
- OCaml
- System setup: OCaml, Opam, Utop etc.
- Primitives: bool, int, Lists, Tuples etc.
- Functions, recursion, currying etc.
- Pattern Matching
- Type annotations
- Built-in modules (List)
- Simple user-defined types
- HW1 solutions
- More on User-defined types
- Recursive data-types
- Polymorphism
- More on Higher-order functions
- HW2 solutions
- Exceptions
- Modules & Functors
- Mid-term solutions
- HW3 hints & clarifications
- Laziness in OCaml
- HW3 solutions
- Inheritance
- Sub-type polymorphism
- vs Parametric polymorphism
- Dynamic dispatch
- vs Static overload
- Implementation in Java
- Generics
super
andextends
- Exceptions
- HW4 solutions
- Java: Pass-by-value vs reference
- Java Streams
- Terminal vs intermediate functions
- Short-circuited functions
- mappers and Function<T,R> sub-type
- Prolog basics