Examines how to program in C++ in a robust and safe manner. Reviews basics, including scoping, typing, and primitive data structures. Discusses data types (primitive, array, structure, class, string); addressing/parameter mechanisms (value, pointer, reference); stacks; queues; linked lists; binary trees; hash tables; and the design of classes and class inheritance, emphasizing single inheritance. Considers the instantiation of objects, the trade-offs of stack vs. heap allocation, and the design of constructors and destructors. Emphasizes the need for a strategy for dynamic memory management. Addresses function and operator overloading; templates, the Standard Template Library (STL), and the STL components (containers, generic algorithms, iterators, adaptors, allocators, function objects); streams; exception handling; and system calls for processes and threads.
This course examines how to program in C++ in a robust and safe manner. C++ is an unsafe programming language, meaning each programmer—not the programming language—must enforce basic invariants concerning abstractions and modularity. The purpose of this course is to introduce students to the programming in C++ and its pitfalls; how standard libraries try to eliminate these pitfalls and fail; and what kind of tools programmers use to overcome the pitfalls.
Lectures consist of a combination of slides, demo, and participation exercises and surveys. Students will need to bring a laptop to class so that they can work along with the code and demos in class.
Lectures will not be recorded, but it is planned that slides and recordings of the same demos used in the live lecture will be posted, an the exercises will be able to be completed after the lecture.
Please check Canvas and Piazza frequently for announcements.
When contacting course staff with a question about your code or grade relating to code in a repository, please include a link to your repository.
Reading for each class will be posted on the schedule. Please read the material before class.
C++ Language Tutorial, cplusplus.com; These tutorials explain the C++ language from its basics up to the newest features of ANSI-C++, including basic concepts such as arrays or classes and advanced concepts such as polymorphism or templates. The tutorial is oriented in a practical way, with working example programs in all sections to start practicing each lesson right away. You can also download the entire tutorial as a PDF.
The course will consist of a number of group assignments, in-class exercises, reading surveys, and an individual final. Grades will be returned through Canvas. Note that the total percentage shown in Canvas is unweighted and may not reflect the actual weighted grading.
We will be using C++17 for the course, unless otherwise specified.
Assignments and exercises are done individually or in pairs. Assignment turnin is on GitHub, and exercise turnin through Canvas.
Surveys are done individually. Turnin will be on Canvas.
The final is done individually. Turnin will be on GitHub.
The expected breakdown of grades is as follows, though tentative and subject to change.
The following scale is expected to be used for overall grades. A curve may be used, but is not guaranteed.
93 - 100: A
90 - 92: A-
87 - 89: B+
83 - 86: B
80 - 82: B-
77 - 79: C+
73 - 76: C
70 - 72: C-
67 - 69: D+
63 - 66: D
60 - 62: D-
0 - 59: F
All assignments due on the day and time indicated on the schedule (generally 9pm). Anything turned in after the deadline will receive a 0. Special circumstances will be handled on a case-by-case basis.
Assignments can be redone once, usually within a few days or week of the grade for that assignment being posted (though assignments near the end of the semester may have a shorter deadline or redos may not be possible). Redo deadlines will be announced when grades are posted. Redos will receive a penalty of -20 points. In the case of pair assignments, a redo can be done individually or jointly. There are no redos on the final, exercises, or surveys.
When submitting a redo, you must email the instructor and the assignment grader with "CS3520 REDO" in the subject, and include your GitHub username and a link to the repo in the email.
Students are encouraged to collaborate through discussing strategies for completing assignments and talking about the readings. You may refer to C++ reference or Q & A sites for help with language features unless otherwise specified on assignments only. However, all work that you turn in with your name on it must be in your own words or coded in your own style. Any code coming from other sources must be cited appropriately. Copying assignments in a large part or wholesale from other students or sources is not allowed. See also LLM policy below.
You should familiarize yourself with the University's policies on academic integrity at the beginning of the semester. If you have any doubts whatsoever about whether you are breaking the rules - ask!
This policy is subject to change during the semester!
Students are allowed to use LLM-based tools (e.g. ChatGPT,
GitHub Copilot, Replit Ghostwriter) on code portions
of assignments only. However, they must be credited as
any other source in the assignment's ABOUT.txt. In addition,
if used, you must add a file called LLM.txt to
your repo that answers the following:
Also check out this AI guide.