|Sections 020X, 040X|
Final exam information:
The final exam will be on Thursday 12/13 from 4:00PM to 6:00PM. Please plan to arrive
at 3:50 so that we can get everything settled.
All students must bring a photo ID to the exam. If you arrive without a photo ID you will be turned away and your grade on the final exam will be 0.
Students must report to the room indicated in the table below. Your room assignment depends on your last name. This table is for all of Fawzi Emad's students (sections 020X and 040X).
|First letter of LAST name||Room Assignment|
|A through C||ESJ 2208|
|D through K||ESJ 0224|
|L through Z||TYD 0130|
11/29/18 Project #7 has been posted.
11/08/18 Project #6 has been posted.
10/28/18 Project #5 has been posted.
10/18/18 Project #4 has been posted.
10/08/18 Project #3 has been posted.
09/23/18 Project #2 has been posted!
09/15/18 If you'd like to have Eclipse draw a vertical line in the editor at the 80th column (so that you can easily check that your lines are not too long), see this link.
09/12/18 Project #1 (Orioles Baseball) has been posted!
09/06/18 I made an error posting yesterday's slides on the class webpage -- the announcements were incomplete. I have corrected the mistake.
09/04/18 The deadline for submitting Project #0 (Hello World) has been moved to Wednesday 9/12.
08/27/18 There is an important survey that we want all CMSC131 students to take. Please click this link for more information and to complete the survey (if you have not already done so).
08/22/18 The first day of class is Monday 08/27. Be sure to attend the lecture that day. If you are in section 040X your lecture is in room ESJ 0202 at 3:00PM. If you are in section 020X, your lecture is in room CSI 1115 at 5:00PM). Note that the discussion sessions for Monday 08/27 are cancelled.
08/22/18 All students are required to attend the class session for which they are registered. This applies to both the lecture session and the discussion session. This rule will be strictly enforced.
08/21/18 This is the class webpage for CMSC131, sections 020X and 040X only. Please check here often (at least once a day) for important class announcements.
This is a first programming course for Computer Science majors with a focus on object-oriented programming. The goal of the course is to develop skills such as program design and testing as well as the implementation of programs using a graphical IDE. All programming will be done in Java.
Course Coordinator: Fawzi Emad
There is no required book for this course. There are many excellent introductory books on programming in Java. One that I can recommend is Java Foundations Older editions of this book are nearly identical to the latest edition, and you can find them sold cheaply online.
There will be eight programming projects and other assignments to be completed during the lab sessions. Some are considered "closed" assignments which you must complete by yourself and others are considered "open" assignments where collaboration is permitted. (More information about the open policy will be provided in class and can be found in the Policy Regarding Open/Closed Projects.) There will also be two midterms, a final exam, and occasional quizzes.
All assignments can be done on the machines of your choice. You are welcome to do the work on a home computer if you have one. There should not be any machine-specific dependencies in your code. If we are not able to run your program because there is a difference between your and our computer environments, you must work with us to get your program to work in our environment. You are expected to use the Eclipse IDE for all programming assignments.
All assignments must be submitted before 11pm on the day they are due. They are to be submitted electronically according to instructions given with the assignments. Late assignments will be strictly penalized. Exceptional circumstances will be considered only if discussed with the instructor before the assignment is due. Late assignments will have points deducted as follows:
Final grades will be computed according the following weights. (These weights are tentative and subject to future adjustment.)
|Percentage||Component||25%||Projects (8) [The weights of the individual projects will vary. Longer/harder projects will be worth more points.]|
|15%||Lab assignments (quizzes & exercises to be completed during your discussion sessions)|
You need to keep backups of your projects as you develop them. No extensions will be granted due to hardware failures or because you accidentally erased your project. Feel free to use the submit server as a backup tool by submitting often. You can also use tools like git, etc. Do not post code in any online system that is accessible to others (e.g., GitHub).
The following are examples of academic integrity violations:
The Department of Computer Science takes the student course evaluations very seriously. Evaluations will usually be open during the last few weeks of the course. Students can go to www.courseevalum.umd.edu to complete their evaluations.
Lecture 01 Slides
|Eclipse demo, computer systems (hardware/software), RAM
Lecture 02 Slides
|data storage, programming languages, compilers/interpreters
Lecture 03 Slides
|Labor Day Holiday||Intro to Java, local variables, primitive types
Lecture 04 Slides
|Continue primitive types, Strings, concatenation, Scanner
Lecture 05 Slides
|Finish primitive types; arithmetic operators, escape sequences, integer division, comparison and equality operators, comparing objects
Lecture 06 Slides
|If and if-else statements, logical operators, nesting if and if-else statements, "else if" style
Lecture 07 Slides
|Continue "else-if" style; programming errors; variable scope and initialization, choosing identifiers, named constants
Lecture 08 Slides
|While loops,do-while loops, for loops
Lecture 09 Slides
|Nested loops, increment/decrement operators
Lecture 10 Slides
|Alternate assignment operators; writing static methods, operator precedence, short-circuiting
Lecture 11 Slides
|Project #2 overview; casting with primitivies; What are objects?
Lecture 12 Slides
|Java classes, instance variables, instance methods, memory diagrams, assignment with references, garbage collection, == vs. equals
Lecture 13 Slides
|Writing a typical Java class (instance members, return types)
Lecture 14 Slides
|Continue writing a typical class (constructors, equals method, toString)
Lecture 15 Slides
|Static vs. instance members; Summary and review of variables
Lecture 16 Slides
|Review for Midterm|
||Continue review of static/instance variables; Overview and intro to Project #3;
Code correctness, formal verification, testing, Begin JUnit
Lecture 19 Slides
|Finish JUnit; Memory diagram for method calls, Begin Java keyword "this"
Lecture 20 Slides
|Finish "this"; public vs. private visibilities, API, data encapsulation
Lecture 21 Slides
|Commenting, Floating point error
Lecture 22 Slides
|Java packages, libraries, API for String and Math classes, break, continue, Intro to exception handling
Lecture 23 Slides
|More exception handling (catch blocks, multiple catch blocks, finally)
Lecture 24 Slides
|More exception handling (multiple catch blocks, finally), Intro to Arrays
Lecture 25 Slides
|More about arrays (iterating, copying, "resizing"), arrays of references, Mutability
Lecture 26 Slides
|StringBuffer, deep vs. shallow copy, Privacy leaks and defensive copies
Lecture 27 Slides
|Finish privacy leaks, using the Eclipse debugger
Lecture 28 Slides
|Corner cases, 2-dimensional arrays, Intro to Java interfaces and polymorphism
Lecture 29 Slides
|Continue Java interfaces, wrapper classes (Integer, Double, etc) and auto-boxing/unboxing
Lecture 30 Slides
|Finish up Java interfaces, method overloading, ternary operator
Lecture 31 Slides
|Switch statements, intro to inheritance, polymorphism via extension, overloading vs. overriding
Lecture 32 Slides
|Object class, correct equals method, package visibility
Lecture 33 Slides
|Javadoc utility, overview of abstract data types and Java collections framework, ArrayList
Lecture 34 Slides
|Review for midterm|
|Midterm #2||Thanksgiving Break|
|ArrayList example, for-each loops, Intro to asymptotic complexity
Lecture 36 Slides
|Big-O notation, intuition for thinking about asymptotic complexity
Lecture 37 Slides
|More big-O examples, intro to recursion
Lecture 38 Slides
|Easy recursion examples
Lecture 39 Slides
|More recursion (including examples requiring a "helper" method)
Lecture 40 Slides
|More recursion examples
Lecture 41 Slides
|Review for final exam (Last day of class)|
Office: 3265 A.V. Williams
Office Hours: MW 1:00-2:00, Fri 12:00 - 1:00
|Carolin Arnold||0201 & 0204 discussion leader||(See table below)|
|Peter Thompson||0202 discussion leader||(See table below)|
|Masataro Koizumi||0203 discussion leader||(See table below)|
|Nick Franzese||0401 & 0409 discussion leader||(See table below)|
|Brennan Hula||0402 discussion leader||(See table below)|
|Goonwanth Namireddy||0403 & 0407 discussion co-leader||(See table below)|
|Deepthi Raghunandan||0403 & 0407 discussion co-leader||(See table below)|
|Anastasiya Stolyarova||0404 discussion leader||(See table below)|
|Isabella Stevens||0406 discussion leader||(See table below)|
|Sigurthor Bjorgvinsson||0501 & 0502 discussion leader||(See table below)|
|Ananth Penghat||0503 discussion leader||(See table below)|
|Roozbeh Bassirian Jahromi||Grader||(See table below)|
|Janit Anjaria||Grader||(See table below)|
|Omer Akgul||Grader||(See table below)|
|Varun Manjunatha||Grader||(See table below)|
|Yixuan Ren||Grader||(See table below)|
|Zhichao Liu||Grader||(See table below)|
|Zehua Zeng||Grader||(See table below)|
|Hamid Kazemi||Grader||(See table below)|
|Fei Shan||Grader||(See table below)|
|Kamal Gupta||Grader||(See table below)|
|Ping-Yeh Chiang||Grader||(See table below)|
All TA office hours take place in room 1112 A.V. Williams. Please note that a TA may need to leave 5 minutes before the end of the hour in order to go to his/her class. Please be understanding of their schedules.
|9:00 - 10:00||Varun||Kamal||Zehua||Deepthi||Varun|
|10:00 - 11:00||Nick||Carolin & Kamal||Nick||Carolin||Varun & Deepthi|
|11:00 - 12:00||Nick||Carolin & Kamal||Nick & Janit||Carolin||Deepthi|
|12:00 - 1:00||Janit & Hamid||Zehua||Janit||Peter||Masa & Hamid|
|1:00 - 2:00||Goonwanth & Omer||Peter & Zehua||Goonwanth & Omer||Peter & Ananth||Masa & Hamid|
|2:00 - 3:00||Omer & Fei||Ana & Goonwanth||Fei||Ana & Goonwanth||Brennan & Hamid|
|3:00 - 4:00||Ananth||Roozbeh & Ping||Fei & Yixuan||Roozbeh & Ping||Zhichao & Yixuan|
|4:00 - 5:00||Ananth & Brennan||Roozbeh & Thor||Isabelle & Yixuan||Roozbeh & Thor||Yixuan & Zhichao|
|5:00 - 6:00||Masa & Ana||Thor||Isabelle||Thor & Ping||Zhichao|
The following web pages provide detailed references to information about Java.
In order to complete the projects for this course you must install Eclipse following the instructions in the Eclipse Tutorial. Note that if you install Eclipse from some other source then you will not be able to submit your projects easily!
After you get Eclipse installed, you will need to connect Eclipse to your class account. To the right is a screenshot of the information you will need to enter into the CVS connection dialog box during this process.
You can cut and paste the following lines into the dialog box:
Be sure to change the connection type to "extssh", as shown.
Below are collections of questions and practice problems that are designed to help you to learn the course material. These exercises are not being collected or graded. Answers are provided, but please try your best to solve each problem before looking at the solution! The list will be updated as the semester progresses.
Disclaimer: Your primary resource for studying should be the notes that you have taken during lectures! There will be questions on quizzes and exams that are not in any way represented in this study list. There will be questions on this study list that are not in any way represented on quizzes or exams. Please be aware that exam questions tend to combine more elements into a single question and many of the questions on the list are simpler than questions you will see on your exams. You may discuss these questions openly with anyone, including your classmates. If you are unsure about how the answer to any particular question is obtained, please drop by office hours for help. That's why we're here!
To submit a project, go to the "Java" perspective in Eclipse. Right click on the project folder (e.g., p1) and select "Submit Project" from the pull-down menu. If you do not see the "Submit Project" option then your copy of Eclipse does not contain the class plug-ins. In this case, please see the Eclipse installations instructions on the Resources page, or drop by TA office hours for help.
You may submit many times (we grade only the last submission). You can check the status of your submissions by visiting the Submit Server Home Page and entering your University Directory ID and password.
Important: Your grade for each project will be based on the greater value of two scores: (1) The score on the very last submission prior to the deadline; (2) The score minus 20% on the very last submission prior to the late deadline (up to 24 hours late).
Click the name of a project below to see the project specification.
|Project Name||Due Date|
|Hello World!||Wednesday 09/12, 11:00PM|
|Orioles Baseball||Sunday 09/23, 11:00PM|
|Flags of the World||Thursday 10/04, 11:00PM|
|Medieval Soldiers||Thursday 10/18, 11:00PM|
|Mandelbrot Set||Sunday 10/28, 11:00PM|
|Poker Simulator||Thursday 11/08, 11:00PM|
|Cafe 131||Thursday 11/29, 11:00PM|
|Fish Club||Monday 12/10, 11:00PM|