- Lecture Time/Location: 3:30pm-4:45pm Tue Thu, Green Center MET
- Contact: jonathanevans (at) mines (dot) edu
- Office Hours: 5:00pm-6:00pm Tue Thu, Zoom
Teaching Assistants (TA)
- Contact: michaelhumphrey (at) mymail (dot) mines (dot) edu
The prerequisite is CSCI-306 Software Engineering. As long as you have some programming experience, that should be sufficient. CSCI-358 Discrete Math is strongly recommended.
This is a difficult class, for several reasons:
- We will take a formal approach to the topics, i.e., we will carefully develop the mathematical/logical underpinnings of programming languages design and implementation. You may not have seen this level of formality in any other CS class so far.
- The class is project-based, meaning you should expect to devote a significant portion of your effort for this class towards writing code.
- Virtually all of the code you write will be in a functional programming language like OCaml. This may be your first exposure to functional programming.
- Programming languages textbooks are often highly technical. We have tried to collect some of the most easily-digestible materials for your reference, but you may find it difficult to master the material without being actively engaged in the class. Class attendance and participation are essential.
Online Community and Communication
In Homework 1, you will be asked to introduce yourself to the instructor. This includes sending a passport-style photo of yourself to the instructor. The photo must be clear, with your face un-obstructed. If you are not comfortable providing a photo, then you will need to contact the instructor to set up a brief Zoom meeting to introduce yourself. Failure to meet this requirement on Homework 1 will result in a 0 (zero) for the Participation component of the grade.
We will use Piazza in the class. This is a great way to ask questions and communicate with the instructor and your classmates. Participation on Piazza is required, and will factor into the Participation component of the grade.
The class Piazza link is: https://piazza.com/class/ke7zken8i6n58f
The instructor will use Piazza to communicate with the class. If you have questions about the course, you should first do a quick search on the Piazza page, to make sure your question has not already been answered there. If not, please go ahead and post your question on Piazza so that the instructor, the TA, or another student can answer it publicly. This will help to streamline the communication.
NOTE #1: neither the instructors nor the TAs will debug your code for you! If you are having difficulty with a certain piece of code, take the time to identify what specific operation(s) is causing unexpected behavior, and ask for help about that. In other words, posting/emailing your source code is not allowed, but asking questions about language features or generic code snippets is welcomed.
NOTE #2: if you have a question you do not wish to publicize (e.g., about your grades, etc.), please create a “private post” on Piazza. Email should only be used in rare instances where use of Piazza would not be feasible.
Textbook and Other Reading Materials
NOTE: the following resources are recommended, but NOT REQUIRED. I will assign readings from these sources to supplement the lectures, but you are only responsible for the information presented in lecture.
- Functional Programming in OCaml by Clarkson et al.
- The Semantics of Programming Languages by Matthew Hennessy
The above links will take you to free versions of the materials.
Class notes will be posted 1-2 days after the lecture. Posted notes are not guaranteed to provide all information discussed in lecture (class attendance is highly recommended).
There is a Github organization for the class: https://github.com/mines-csci400 All of your individual/team repositories will show up there.
The following percentages show how final grades will be calculated. I will not perform any rounding on the scores (e.g., a score of 92.999 will not be rounded up to 93). I may or may not curve the overall grades, depending on how well the class performs overall, however, I expect each student to work hard, and not rely on the curve!
Many of us are facing exceptional difficulties due to the pandemic, remote learning, etc., so I am starting everyone’s overall grade at 56%. If your goal is to pass the class, that should be attainable with minimal effort. If your goal is to obtain an “A”, you will still need to take the class seriously, and put in effort on each assignment/exam, as well as actively participate.
Late policy: late submissions are accepted up to 5 days after the deadline, with a penalty of -20% per day applied.
Letter grades will be calculated based on the following intervals:
Class attendance is not required, but is highly recommended (see above info about Class Notes).
We will use GitHub for collaboration. We will use private individual and team-specific repositories to submit assignments. Your repositories will show up here: https://github.com/mines-csci400
Respectfulness and Academic Honesty
Every student is expected to show respect to the instructors and the rest of the class. This course is preparation for your future career, so make sure you are behaving with the same level of professionalism that would be expected at a future full-time position. The general rule of thumb is: informal is okay, but disrespectful is not.
- It is vital that you do your best to participate in the class, and communicate with the instructor(s) about any course-related difficulties you are facing.
Plagiarism/cheating is NOT acceptable, and will be met with the maximum available penalty. Sophisticated plagiarism-detection software will be used on every submitted assignment, and all confirmed instances of cheating will be immediately reported to the Computer Science department. Please ensure that you do not engage in or facilitate academic dishonesty in this class!
The Colorado School of Mines is committed to ensuring the full participation of all students in its programs, including students with disabilities. If you anticipate or experience any barriers to learning in this course, please feel welcome to discuss your concerns with me. Students with disabilities may also wish to contact Disability Support Services (DSS) to discuss options to removing barriers in this course, including how to register and request official accommodations. Please visit their website at https://disabilities.mines.edu for contact and additional information. If you have already been approved for accommodations through DSS, please meet with me at your earliest convenience so we can discuss your needs in this course.
This schedule is tentative, and is subject to change. Deadlines are at 11:59pm (Mountain Time) on the corresponding date.
|1||Aug 25||PL and functional programming||course intro, overview||lecture01||hw 1 assigned|
|2||Sep 1||PL and functional programming||functional programming (simple functional language)||lecture03||Semantics of PL ch 3||hw 1 due|
|Sep 3||PL and functional programming||crash course on Linux, OCaml, OPAM, Git||lecture04||OCaml Online REPL, Git Cheat Sheet , OCaml Exercises|
|3||Sep 8||PL and functional programming||crash course on Linux, OCaml, OPAM, Git||lecture05||Learn OCaml, OCaml Spec, Ocaml Module Reference||hw 2 assigned|
|Sep 10||expressions and evaluation||algebraic data types (ADTs), pattern matching||lecture06||Data Types|
|4||Sep 15||no class (career day)||lab 1 assigned|
|Sep 17||expressions and evaluation||algebraic data types (ADTs), pattern matching||lecture07||Data Types||hw 2 due|
|5||Sep 22||expressions and evaluation||syntax, grammars||lecture08||Semantics of PL ch 1.2||hw 3 assigned|
|Sep 24||syntax and semantics||lexing, parsing||lecture09||Lexing, Parsing, Lexing & Parsing|
|6||Sep 29||syntax and semantics||OCaml parser generators||lecture10||Ocaml Parser Generators|
|Oct 1||syntax and semantics||induction and recursion||lecture11||Semantics of PL ch 1.3||lab 1 due|
|7||Oct 6||syntax and semantics||inductive definitions, structural induction||lecture12||Semantics of PL ch 1.4-1.5||lab 2 assigned|
|Oct 8||syntax and semantics||big-step operational semantics||lecture13||Environment Model, Semantics of PL ch 4||hw 3 due|
|8||Oct 13||higher-order functions||lecture14||Higher-order Programming||hw 4 assigned|
|Oct 15||take-home midterm|
|9||Oct 20||no class (holiday)|
|Oct 22||higher-order functions||recursive higher-order functions||lecture15||Evaluating Lambdas||lab 2 due|
|10||Oct 27||higher-order functions||static/dynamic scoping||lecture16||Evaluating Lambdas||lab 3 assigned|
|Oct 29||higher-order functions||closures||lecture17||Implementing Closures||hw 4 due|
|Nov 5||type checking||dynamic typing||lecture19||Type Checking|
|12||Nov 10||mutable variables and objects||static type checking||lecture20||Hindley-Milner|
|Nov 12||mutable variables and objects||type inference||lecture21||Semantics of PL ch 5.1-5.2||lab 3 due|
|13||Nov 17||mutable variables and objects||small-step operational semantics||lecture22||Semantics of PL ch 5.3||lab 4 assigned|
|Nov 19||mutable variables and objects||small-step operational semantics||lecture23||Mutability||hw 5 due|
|14||Nov 24||no class|
|Nov 26||no class (holiday)|
|15||Dec 1||advanced topics||lecture24||Mutable Fields|
|Dec 3||(exam review)||lecture25||Currying||lab 4 due|
|16||Dec 8||take-home final|
|Dec 10||no class (study for finals)|
|17||Dec 15||no class (final exam week)|
|Dec 17||no class (final exam week)|
There will be 4 labs. Lab 1 will be individual, and Labs 2-4 will be completed in groups of 2-3 students. Your lowest lab score will be discarded before the final grade is calculated! You will have approximately 3 weeks to work on each lab. The labs build on each other, and lab solutions will NOT be provided, meaning you will need to pay special attention to building a collection of test cases, to ensure that bugs in earlier lab submissions do not propagate into later labs.
- Lab 1: Learning OCaml
- Lab 2: Expression evaluation
- Lab 4: Implementing recursive higher-order functions
Lab 5: Closures, type checking Lab 6: Objects, mutable variables
There will be approximately 5 homeworks, which will be completed individually. Your lowest homework score will be discarded before the final grade is calculated! These are designed to help encourage you to keep up-to-date on the course material. You will have approximately 3 weeks to work on each homework.
- Homework 1: Course preliminaries
- Homework 2: Scala preliminaries
- Homework 3: Lexing & Parsing
- Homework 4: Structural induction
- Homework 5: Big-step semantics
Homework 6: Recursive functions Homework 7: Type inference
This course is inspired by Bor-Yuh Evan Chang’s fantastic Programming Languages course. Special thanks to Evan for his advice and assistance.