CMSC 330
Organization of Programming Languages,
Fall 2019

Instructors

Name Office E-mail Office Hours
(also available by appointment)
Roger D. Eastman IRB 1126 reastman@cs.umd.edu M 3:00-4:00pm Tu/Th 2:30-4:00 pm
Anwar Mamat IRB 2244 anwar@cs.umd.edu TuTh 12:00-1:00pm

TAs

Name E-mail
Aaron Alemaalem78@gmail.com
Clifford Bakaliancliffbakalian@gmail.com
Cameron Bernhardtcambernhardt@me.com
Zain Bhailazainb@terpmail.umd.edu
Paaras Bhandaripaarasbhandari@gmail.com
Austin Bradyabrady@terpmail.umd.edu
Vincent Caprarolavcapra1@gmail.com
Yuexi (Tracy) Chenychen151@cs.umd.edu
Liam Dunnliamsdunn1@gmail.com
Olasubomi Efuniyisubsefun@gmail.com
Alex Engaveng731@gmail.com
Asher Finkfinka@umd.edu
Danielle Firerdfirer@terpmail.umd.edu
Jonah Freemanjfreem@terpmail.umd.edu
Salma Ghorabghorabsalma@gmail.com
Marziyeh Khodadadzadehmarzi.kh1998@gmail.com
Eric Lilieric@terpmail.umd.edu
Noah McCordnoahcmccord@gmail.com
Jordan Messjmess@umd.edu
Christopher Neidhartcneidhar@terpmail.umd.edu
Ashan Panduwawala ashan399@gmail.com
Ian Parksiparks@terpmail.umd.edu
Naveen Ramannav.j.raman@gmail.com
Mihailo Rancicrancic.minya@gmail.com
Pavan Ravindrapravin4094@gmail.com
Shruti Rayrayshruti@gmail.com
Stephen Riskastephenriska123@gmail.com
Shilpa Royshilparoy4899@gmail.com
TJ Shresthashrestha.tj@gmail.com
Arun Srinivasasrini16@terpmail.umd.edu
Barath Srinivasanbarath5999@gmail.com
Camille Stachocamstach@gmail.com
Jason Starkeyjstarkey0919@gmail.com
Michael Stephanusmichaelstephanus82@yahoo.com
Suteerth Vishnusvishnu@umd.edu
Matthew Woernermwoerner77@gmail.com
Andrew Wollackandrew.wollack@gmail.com
Thomas Wronatomdwrona@gmail.com
Willem Wyndhamwillem@cs.umd.edu
Richard Yurichardyu042@gmail.com
Sabrina Zhousabrina.zhou.m@gmail.com

Information

Location Section 1: TuTh 5:00-6:15pm ESJ 0202
Section 2: TuTh 9:30am-10:45am IRB 0324
Midterm 1 Oct 10 (in class)
Midterm 2 Nov 14 (in class)
Final Wednesday, December 11 4:00-6:00pm
Location: TBD
Textbooks There are no required or recommended texts. See the resources page for useful online links.

Discussions

0101BarathF 12:00pm - 12:50pmIRB 1207
0102CameronF 1:00pm - 1:50pmIRB 1207
0103OlasubomiF 2:00pm - 2:50pmIRB 1207
0104VincentF 3:00pm - 3:50pmIRB 1207
0105PavanF 10:00am - 10:50amIRB 2107
0106MichaelF 4:00pm - 4:50pmIRB 1207
0107CliffordF 12:00pm - 12:50pmIRB 2107
0108ShrutiF 1:00pm - 1:50pmIRB 2107
0109SalmaF 10:00am - 10:50amIRB 2118
0201ShilpaF 2:00pm - 2:50pmIRB 2207
0202MihailoF 3:00pm - 3:50pmIRB 2207
0203ArunF 10:00am - 10:50amIRB 1207
0204DanielleF 11:00am - 11:50amIRB 1207
0205NoahF 2:00pm - 2:50pmIRB 2107
0206ChristopherF 3:00pm - 3:50pmIRB 2107
0207LiamF 4:00pm - 4:50pmIRB 2107
0208SuteerthF 11:00am - 11:50amIRB 2107
0209SabrinaF 10:00am - 10:50amIRB 2207

Office Hours: (IRB 1108) (Office hour scheduling app)

10:00Marzi, ThomasPavan, TracyMarzi, Naveen, ThomasSubomi, TracyShilpa
11:00Marzi, ThomasTracy, Jason, SalmaMarzi, Naveen, ThomasTracy, MinyaArun, Barath, Jordan
12:00StephenJason, AshanStephen, Paaras, CamilleJason, Asher, NaveenShruti, Cameron, Suteerth
1:00Stephen, Matthew, AaronAshan, Willem, ZainVincent, Danielle, CamilleAsher, NaveenCliff, Jordan
2:00Paaras, Aaron, AsherWillem, Zain, AustinEric, Vincent, CamilleZain, MatthewJason, Jordan, Eric
3:00Paaras, Asher, RichardWillem, Austin, AlexEric, Jordan, CamilleZain, LiamEric, Stephen
4:00Austin, Jonah, RichardWillem, Alex, AaronAlex, AshanAlex, PaarasRichard, Jonah
5:00Jonah, SabrinaAaron, ChrisAshan, TJ, MatthewIan, TJRichard, Ian, TJ
6:00Jonah, MichaelMatthew, NoahIan, AustinIan, TJ

Class announcements will be posted via Piazza; please check the course Piazza page daily. You may sign up for the class on Piazza here.

A study of programming languages, including their syntax, semantics, and implementation. Several different models of languages are discussed, including procedural (Ruby), functional (OCaml), and object-oriented (Java). Language features such as formal syntax, scoping and binding of variables, higher-order programming, typing and type polymorphism, and object inheritance are explored.

Week/Day Tuesday
Aug 27 Introduction(slides)
Ruby 1(slides)
Aug 29 Ruby 2(slides)
Sep 3 Ruby Hash(slides)
Code Blocks (slides)
Sep 5 Ruby Regular Expressions(slides) Lecture Notes
Regex Cheat sheet(pdf)
Sep 10

Ruby Mixins(slides) Lecture Notes
OCaml Introduction(slides)

Working with OCaml(slides)

Lecture Notes
Sep 12 OCaml Functions (slides)
Sep 17

OCaml List and Tuples(slides)

Lecture Notes

Sep 19

Lets and tuples(slides)

Higher Order Functions (slides)

Lecture Notes

Sep 24 Higher Order Functions (slides)
Lecture Notes
Data Types(slides)
Lecture Notes
Sep 26 Closures(slides)
Lecture Notes
Oct 1 Imperative OCaml(slides)
Oct 3 Finite Automata(slides)
Oct 8 DFA/NFA(slides)
Oct 10 Midterm 1
Oct 15 DFA/NFA(slides)
Context Free Grammars(slides)
Oct 17 Context Free Grammars(slides)
Oct 22 Parsing(slides)
Code (github)
Oct 24 Operational Semantics(slides)
Code (github)
Oct 29 Lambda Calculus (slides)
Code (github)
Oct 31 Lambda Calculus Encodings(slides)
Nov 5 Rust Basics(slides)
Nov 7 Rust Basics: Ownership(slides)
Nov 12 OCaml Modules (slides)
Modules (github) Functor (github)
Nov 14 Midterm 2
Nov 19 OCaml Lazy Evaluation and Streams (slides)
Code(github)
Nov 21 Software Security(slides)
  • Quiz 2,3 DFA, NFA, CFG Sample Quizzes

Syllabus subject to change until the start of the semester
Prerequisites: Prerequisites: C- or better in CMSC 216 and CMSC 250
Credits: 3 credits

A study of programming languages, including their syntax, semantics, and implementation. Several different models of languages are discussed, including dynamic, scripting (e.g., Ruby, Python) functional (e.g., OCaml, Haskell, Scheme), and concurrent/parallel (an aspect of many languages). Language features such as formal syntax, scoping and binding of variables, higher-order programming, typing and type polymorphism, and concurrent language features will be explored.

List of Topics (subject to change)

The following list of lecture topics will vary according to the pace of lecture.
  • Dynamic Languages (Ruby)
    • Implicit vs. explicit declarations
    • Dynamic vs. static typing
    • Text processing and string manipulation
  • Regular expressions and finite automata
  • Context-free grammars and parsing
  • Functional programming (OCaml)
    • Lists and recursion
    • Type inference and polymorphism
    • Higher-order functions and closures
    • Static (lexical) vs. dynamic scoping
    • Modularity and abstraction
  • Software security
    • Design anti-patterns that lead to security flaws
    • Defenses against security attacks
  • Advanced Topics
    • Lambda calculus
    • Operational Semantics
    • Garbage collection and memory management
    • History of Programming Languages

Computing Resources

Programming projects can be developed on the Grace Cluster www.grace.umd.edu. Accounts are distributed via the grades server, grades.cs.umd.edu. Log in with your OIT account; if you do not have a OIT account, request one immediately online.

If you have access to another system you are welcome to do your development there instead, but all project submissions must work correctly on the Grace cluster, and your projects will be graded solely based on their results on the cluster (by the submit server). Because language and library versions may vary with the installation, in unfortunate circumstances a program might work perfectly on your system but not work at all on the cluster. Thus we strongly recommend that if you develop any project on another system, you should complete it several days early to have time to address any compatibility problems.

Grading

Grades will be maintained on the CS Department grades server. You can always see your current grade here.

You are responsible for all material discussed in lecture and discussion section and posted on the class web page, including announcements, deadlines, policies, etc. During the semester we may provide ungraded practice homework exercises and solutions. While we will not collect these exercises, completing them is essential preparation for exams. You may work together on these ungraded homeworks, and you may of course come to office hours for additional help.

Your final course grade will be determined according to the following percentages:

Assignment Percentage
6 Programming Projects 40% Total
4 Quizzes
  1. Ocaml (10/4)
  2. DFA, NFA (10/18)
  3. Operational Semantics, Parsing, CFG (11/01)
  4. Lambda Calc (11/22)
8% Total
Clicker Quizzes 4% Total
Discussion Exercises 2% Total
2 Midterms 12% Each
Final 22%

Any request for reconsideration of any grading on coursework must be submitted within one week of when it is returned (or published on gradescope). Exam regrading requests must be made through gradecscope. Any coursework submitted for reconsideration may be regraded in its entirety, which could result in a lower score if warranted.

Final course grades will be curved as necessary, based on each student's total num score for all coursework at the end of the semester. But: It is very likely that 90 and above earns an A, 80-90 earns a B, 70-80 earns a C, etc.; the curve will only lower the cutoffs, not raise them. Important: Completing the programming assignments is an essential part of the course. Therefore, we may fail any student who does not make a good-faith attempt on all course projects, regardless of the student's performance or scores on the other coursework. We will define good-faith attempt as achieving at least 20 percent on the submit server for each project. To obtain these points you may submit solutions past the late deadline.

Programming Projects

Projects must be submitted electronically following the instructions given in class. Projects may not be submitted by any other means (e.g., please do not email your projects to us). It is your responsibility to test your program and verify that it works properly before submitting. All projects are due at 11:59pm on the day indicated on the project assignment, according to the submission server's internal clock.

Projects may be submitted up to 24 hours late for a 10% penalty. For example, a project that would earn 90 points for an on-time submission will earn 81 (which is 90 times 0.90) if submitted late. Note that your project score as it appears on the project submission server will not include any late penalties. Any penalties will be incorporated into the final project grade on the grade server. If you submit both on-time & late, your project will receive the maximum of the penalty-adjusted scores.

Project extensions will not be granted due to system problems, network problems, power outages, etc., so do not wait to submit a project until the night it is due. You may submit multiple times up to the deadline, and only your last on-time submission is graded. Similarly, if you submit late, only your last submission before the deadline will be graded. No consideration in grading will be made for errors made in transferring files or submitting the wrong version of your project. Having a working, unsubmitted version will not count; only submitted code will be counted.

Your projects will be graded based on test cases not provided in advance. Because grading is done automatically, you must follow the project specification exactly. Also, while projects will generally not be graded on style or documentation, we reserve the right to manually grade program source code for some projects.

Finally, any "hard coding" in a project assignment may result in a score of zero for that project, and is considered a bad-faith effort. Hard coding refers to attempting to make a program appear as if it works correctly, when in fact it does not. One example of hard coding would be printing the desired output instead of computing it. This is only one example, and if you have any questions as to what constitutes hard coding, be sure to ask ahead of time.

Do not share or publicly post your project solutions on-line; doing so constitutes a violation of academic integrity. This issue is discussed in greater detail below.

Clicker Quizzes

Clicker quizzes will be given in-class during lectures. Effective August 22, 2017, students and faculty at UMD have access to TurningPoint (Clickers) mobile license subscriptions at NO cost. You can purchase a clicker device or use the phone app. Clicker device costs $16 at the University bookstore. You also have to register your device here: https://myelms.umd.edu/courses/1020311

Laptops in class

In general, we discourage the use of laptops in class. Not only are they a distraction for their user, they are a distraction for students around that user. For those who wish to use laptops to take notes, please sit in the back two rows of the lecture hall. Elsewhere, laptops must remain closed.

Outside-of-class communication with course staff

We will interact with students outside of class in primarily three ways: in-person during office hours, electronically via the web forum and course web page, and electronically via e-mail. The large majority of communication should employ the first two methods, reserving e-mail for personal (presumably rare) circumstances.

Personalized assistance, e.g., with programming assignments or exam preparation, will be provided during office hours. You are responsible for developing and debugging your own programs. Do not rely on the instructional staff to make your project work. Lower-level CMSC courses provide extensive debugging and development help in office hours, but upper-level CMSC courses expect students to complete projects with minimal extra help. Therefore in CMSC 330, we will provide less debugging help than some students may be used to. If you come in with a question, expect to be pointed in the right direction, but it will be up to you to finish solving the problem on your own. Office hours for the instructional staff will be posted on the course web page a few days into the semester.

Additional assistance will provided via the Piazza web forum. You may use this forum to ask general questions of interest to the class as a whole, e.g., administrative issues or project clarification questions. The course staff will monitor piazza on a daily basis, but do not expect immediate answers to questions. Please do not post publicly any information that would violate the university academic integrity policy (e.g., project code or test cases).

Piazza allows students to post private questions that are only visible to instructors. Please use this feature if you wish to ask specific questions concerning your project solutions. Generally it will also be helpful to submit your current project code to the submit server, so instructors & TAs can try running your code on their machines before answering your questions.

Personal e-mail to instructors or TAs should be reserved for issues that cannot be handled by the above methods.

Important announcements will be made in class or on the class web page, and via piazza.

Excused Absences

Any student who needs to be excused for an absence from a single lecture, recitation, or lab due to illness shall:

  1. Make a reasonable attempt to inform the instructor of his/her illness prior to the class.
  2. Upon returning to the class, present their instructor with a self-signed note attesting to the date of their illness. Each note must contain an acknowledgment by the student that the information provided is true and correct. Providing false information to University officials is prohibited under Part 9(h) of the Code of Student Conduct (V-1.00(B) University of Maryland Code of Student Conduct) and may result in disciplinary action.

Missing an exam for reasons such as illness, religious observance, participation in required university activities, or family or personal emergency (such as a serious automobile accident or close relative's funeral) will be excused so long as the absence is requested in writing at least 2 days in advance and the student includes documentation that shows the absence qualifies as excused; a self-signed note is not sufficient as exams are Major Scheduled Grading Events. For this class, such events are the final exam, the two midterms, and quizzes, which will be given in class.

For medical absences, you must furnish documentation from the health care professional who treated you. This documentation must verify dates of treatment and indicate the timeframe that the student was unable to meet academic responsibilities. In addition, it must contain the name and phone number of the medical service provider to be used if verification is needed. No diagnostic information will ever be requested. Note that simply being seen by a health care professional does not constitute an excused absence; it must be clear that you were unable to perform your academic duties.

It is the University's policy to provide accommodations for students with religious observances conflicting with exams, but it is the your responsibility to inform the instructor in advance of intended religious observances. If you have a conflict with one of the planned exams, you must inform us prior to the end of the first two weeks of the class.

For missed exams due to excused absences, the instructor will arrange a makeup exam. If you might miss an exam for any other reason other than those above, you must contact the instructor in advance to discuss the circumstances. We are not obligated to offer a substitute assignment or to provide a makeup exam unless the failure to perform was due to an excused absence.

The policies for excused absences do not apply to project assignments. Projects will be assigned with sufficient time to be completed by students who have a reasonable understanding of the necessary material and begin promptly. In cases of extremely serious documented illness of lengthy duration or other protracted, severe emergency situations, the instructor may consider extensions on project assignments, depending upon the specific circumstances.

Besides the policies in this syllabus, the University's policies apply during the semester. Various policies that may be relevant appear in the Undergraduate Catalog.

If you experience difficulty during the semester keeping up with the academic demands of your courses, you may consider contacting the Learning Assistance Service in 2201 Shoemaker Building at (301) 314-7693. Their educational counselors can help with time management issues, reading, note-taking, and exam preparation skills.

Students with Disabilities

Students with disabilities who have been certified by Disability Support Services as needing any type of special accommodations should see the instructor as soon as possible during the schedule adjustment period (the first two weeks of class). Please provide DSS's letter of accommodation to the instructor at that time.

All arrangements for exam accommodations as a result of disability must be made and arranged with the instructor at least three business days prior to the exam date; later requests (including retroactive ones) will be refused.

Academic Integrity

The Campus Senate has adopted a policy asking students to include the following statement on each examination or assignment in every course: "I pledge on my honor that I have not given or received any unauthorized assistance on this examination (or assignment)." Consequently, you will be requested to include this pledge on each exam and project. Please also carefully read the Office of Information Technology's policy regarding acceptable use of computer accounts.

Programming projects are to be written individually, therefore cooperation or use of unauthorized materials on projects is a violation of the University's Code of Academic Integrity. Both the person receiving assistance and the person providing assistance are in violation of the honor code. Any evidence of this, or of unacceptable use of computer accounts, use of unauthorized materials or cooperation on exams or quizzes, or other possible violations of the Honor Code, will be submitted to the Student Honor Council, which could result in an XF for the course, suspension, or expulsion.

  • For learning the course concepts (including the programming languages), students are welcome to study together or to receive help from anyone else. You may discuss with others the project requirements, the features of the programming languages used, what was discussed in class and in the class web forum, and general syntax errors. Examples of questions that would be allowed are "Does a Java class definition end in a semicolon?" or "What does a 'class not found' error indicate?", because they convey no information about the contents of a project.
  • When it comes to actually writing a project assignment, other than help from the instructional staff a project must solely and entirely be your own work. Working with another student or individual, or using anyone else's work in any way except as noted in this paragraph, is a violation of the code of academic integrity and will be reported to the Honor Council. You may not discuss design of any part of a project with anyone except the instructor or teaching assistants. Examples of questions you may not ask others might be "How did you implement this part of the project?" or "Please look at my code and help me find my stupid syntax error!". You may not use any disallowed source of information in creating either their project design or code. When writing projects you are free to use ideas or short fragments of code from published textbooks or publicly available information, but the specific source must be cited in a comment in the relevant section of the program.

Violations of the Code of Academic Integrity may include, but are not limited to:

  1. Failing to do all or any of the work on a project by yourself, other than assistance from the instructional staff.
  2. Using any ideas or any part of another person's project, or copying any other individual's work in any way.
  3. Giving any parts or ideas from your project, including test data, to another student.
  4. Allowing any other students access to your program on any computer system.
  5. Posting solutions to your projects to publicly-accessible sites, e.g., on github. (Note that if you want to use Git, you can request free, private accounts from Bitbucket.)
  6. Transferring any part of a project to or from another student or individual by any means, electronic or otherwise.

If you have any question about a particular situation or source then consult with the instructors in advance. Should you have difficulty with a programming assignment you should see the instructional staff in office hours, and not solicit help from anyone else in violation of these rules.

It is the responsibility, under the honor policy, of anyone who suspects an incident of academic dishonesty has occurred to report it to their instructor, or directly to the Honor Council.

Every semester the department has discovered a number of students attempting to cheat on project assignments, in violation of academic integrity requirements. Students' academic careers have been significantly affected by a decision to cheat. Think about whether you want to join them before contemplating cheating, or before helping a friend to cheat.

You are welcome and encouraged to study and compare or discuss their implementations of the programming projects with any others after they are graded, provided that all of the students in question have received nonzero scores for that project assignment, and if that project will not be extended upon in a later project assignment.

Course Evaluations

If you have a suggestion for improving this class, don't hesitate to tell the instructor or TAs during the semester. At the end of the semester, please don't forget to provide your feedback using the campus-wide CourseEvalUM system. Your comments will help make this class better. CourseEvalUM is scheduled to be open between Tuesday, December 1 and Sunday, December 13, but this is subject to change by campus.

Right to Change Information

Although every effort has been made to be complete and accurate, unforeseen circumstances arising during the semester could require the adjustment of any material given here. Consequently, given due notice to students, the instructors reserve the right to change any information on this syllabus or in other course materials.

Copyright

All course materials are copyright Dept. of Computer Science, University of Maryland (Marvin Zelkowitz, Jeff Foster, Larry Herman, Atif Memon, Chau-Wen Tseng, Michael Hicks, David Levin, Nelson Padua-Perez,Anwar Mamat). All rights reserved. Students are permitted to use course materials for their own personal use only. Course materials may not be distributed publicly or provided to others (excepting other students in the course), in any way or format.

Quick Reference

Software Installation

VirtualBox Linux VM

  • If you want to work in a virtual Linux environment on your Windows computer, you can use a virtual machine. First, you have to download VirtualBox from https://www.virtualbox.org/ and install it. Then download the Linux VM image file CMSC330.zip, and open it with VirtualBox. This Linux image have Ruby, OCaml, and emacs installed. You can install other tools if you want.
  • Linux VM Image (CMSC330.zip, 2.8GB) (Linux admin user name: cmsc330, password: cmsc330)

Ruby

  • ruby-lang.org - The main Ruby website.
  • Quick Start (Ruby in 20 minutes)
  • Introduction to Ruby - A simple introduction to basic Ruby
  • PythonTutor for Ruby - An interactive, web-based visual debugger for Ruby programs
  • The Pragmatic Programmer's Guide - "The Pickaxe Book" is a more comprehensive overview of Ruby. It's an online version of the first edition of a printed Ruby book. The only thing to keep in mind is that it covers Ruby 1.6, while you can buy the newest printed version which covers the Ruby 1.9 and 2.0. We probably won't do anything for this course where the difference between versions. There's a lot of information here which you won't need- the most relevant sections are the first fourteen listed (the first up through "Basic Input and Output"), then "When Trouble Strkes", "Ruby and Its World", and "The Ruby Language" and "Classes and Objects". These last two are good summary references for the language.
  • Ruby Class Reference
  • Ruby documentation - A list from ruby-lang.org of Ruby reference manuals, online sources of Ruby information (some of the ones which will probably be more useful are mentioned specifically below), and Ruby articles. If you want to buy a printed book about Ruby several are listed.
  • Ruby User's Guide - An English translation of a book written by the designer of the language. More of a language reference than a tutorial.

OCaml

Rust

Formal grammars and finite automata

Lambda calculus

Java Garbage Collection

Ruby On Rails

  • Rails is a full-stack framework for developing database-backed web applications according to the Model-View-Control pattern.

Git

 

Other relevant texts

Previous required texts for CMSC 330 have chapters on relevant topics covered in this course. If the lecture notes are insufficient, look for these books. They should be available in the university library.

  • Concepts of Programming Languages (Seventh Edition) by R. Sebesta, Addison Wesley (2006) (ISBN 0-321-33025-0).
  • Programming Languages: Design and Implementation (Fourth Edition) by T. Pratt and M. Zelkowitz, Prentice Hall (2001) (ISBN 0-13-027678-2).
  • O'Reilly History of Programming Languages Poster