Archived · Fall 2023

CS 121 Computer Science I

All offerings: Fall 2018Spring 2019Fall 2019Spring 2020Fall 2020Fall 2021Fall 2022Spring 2023Fall 2023 Current course page →
This is the course website as it was published for Fall 2023. Dates, links and policies reflect that semester and may be out of date; see the current course page for the latest version.

Course Info

The fundamental concepts of computer science, with an emphasis on Python programming.

Instructor:

Dr. Peilong Li

Office:

Nicarry 208

Appointments:

By email

Number of Credits

4

Pre-requisites

  • Enthusiasm on programming
  • High school algebra

Textbooks

  • (Required) zyBooks. CS 121: Computer Science I. Sign in or create an account at learn.zybooks.com. Enter zyBook code: ETOWNCS121Fall2023. Subscribe. A subscription is $89. Students may begin subscribing on Aug 08, 2023. Subscriptions will last until Dec 27, 2023.

  • (Optional) Allen B. Downey. Think Python, 2nd Ed. 2015, O’Reilly Media, Inc., ISBN: 9781491939369. E-copy: link

Course Overview

Course Coverage

Explore the foundational principles of computer organization, data representation, algorithmic development, and structured programming. Emphasizing Python’s syntactic and execution traits, delve into data types, arithmetic operations, input/output mechanisms, selection and iteration constructs. Discover procedural abstraction, arrays, object-oriented programming, class design, and harness Python’s power for Data Science.

Student Learning Outcomes

By the end of the course, students will be able to:

  • Apply fundamental computing and mathematical knowledge, including data structures and basic algorithms, to effectively solve problems using Python.
  • Design, implement, and evaluate computer-based systems, processes, components, or programs to fulfill specific requirements.
  • Describe and apply the core principles of the software development cycle in the context of Python programming.
  • Demonstrate proficiency in adhering to coding standards, style guidelines, and documentation practices.
  • Develop a solid understanding of data types and object-oriented programming concepts.
  • Utilize Python for Data Science, including data manipulation, analysis, and visualization, to gain insights from real-world datasets.
  • Apply Python programming constructs like strings manipulation, basic I/O operations, Boolean algebra, selection statements, loop statements, and arrays to effectively solve computational challenges using both procedural and object-oriented paradigms.

Course Schedule

Note this tentative schedule is subject to change. Please check the schedule regularly.

Last updated: 08/21/2023

Week Starting Topics Reading Notes
1 8/21/23 M: Lec1 - Course Intro & Computer Science
W: Lec2 - Demo of Course Tools & First Program Week1-1
F: Lec3 - Values, Data Types and Operations Week1-2
2 8/28/23 M: Lec4 - Function Calls & Type Conversion Functions Week2-1
W: Lec5 - Variables & Input, Lab 1 - Variables and I/O Week2-2
F: Dr. Li on Travel - Complete Lab 1 with TA Week2-3
3 9/4/23 M: Labor Day - No Class
W: Lec6 - Debut of Turtle & OOP Concepts Week3-1 Wed: Project 1 out.
F: Lec7 - A Herd of Turtles & More Turtle Methods Week3-2
4 9/11/23 M: Lec8 - Repetition with a for Loop Week4-1
W: Lec9 - Boolean Expressions, Logical Operators Week4-2
F: Lab 2 - Conditions and Repetitions Week4-3
5 9/18/23 M: Lec10 - Conditional Execution Week5-1
W: Lec11 - The Listener Loop: while Loops Week5-2 Wed: Project 1 due. Project 2 out.
F: Lec12 - Functions (1) Week5-3
6 9/25/23 M: Lec13 - Functions (2) Week6-1
W: PE1 - Loops and Functions Week6-2
F: Lab 3 - Functions Week 6-3
7 10/2/23 M: Lab Test 1
W: Midterm Exam
F: Fall Break - No Class
8 10/9/23 M: Lec14 - Strings Week8-1
W: Lec15 - Tuples and Lists Week8-2 Wed: Project 2 due. Project 3 out.
F: Lec16 - Dictionaries Week8-3
9 10/16/23 M: Lec17 - Iterations Week9-1
W: Lec18 - Accumulation Week9-2
F: PE2 - Data Structures Week9-3
10 10/23/23 M: Lec19 - OOP Classes and Objects. Week10-1
W: Lec20 - Instance methods Week10-2
F: Lab 4 - Data Structures Week10-3
11 10/30/23 M: Lec21 - Class attribute and class methods Week11-1
W: Lec22 - Class customization Week11-2 Wed: Project 3 due. Project 4 out.
F: PE3 - OOP Week11-3
12 11/6/23 M: Lab 5 - OOP Week12-1
W: PE4 - OOP and Data Structures Week12-2
F: Lab Test 2
13 11/13/23 M: Lec23 - Python for Data Science and AI Week13-1
W: Lec24 - Pandas DataFrame Week13-2 Wed: Project 4 due. Project 5 out.
F: Lec25 - DataFrame Operations Week13-3
14 11/20/23 M: Lec26 - Data Visualization Week14-1
W: PE5 - Pandas Week14-2
F: Thanksgiving Break - No Class
15 11/27/23 M: Lab 6 - Pandas All
W: Course Review All
F: Final Exam Q&A All Fri: Project 5 due.
16 12/4/23 M: Final Exam: 7:30-10:30 AM
W: Good luck with your finals
F: Good luck with your finals

Grading Policies

Grading Weights

The final grade for this course depends upon the grades and scores earned on course components weighted as follows:

  • 5%: X in-class pop quizzes.
  • 20%: Bi-daily reading and coding homework.
  • 20%: 5 team projects.
  • 15%: 6 in-class labs (drop the lowest grade).
  • 15%: 2 lab tests.
  • 10%: 1 midterm exam.
  • 15%: 1 final exam.

Grades will be computed by rounding numerical percentages to the nearest integer and applying the following table:

Letter Range Letter Range Letter Range
A 93-100 B- 80-82 D+ 67-69
A- 90-92 C+ 77-79 D 63-66
B+ 87-89 C 73-76 D- 60-62
B 83-86 C- 70-72 F 0-59

Bi-daily Reading Homework

All reading and coding homework assignments have to be completed individually in this course. All the bi-daily homework will be released at the beginning of the semester. Each homework is due by 9:30 AM on the class day. For example, “Reading Week 2-2” is due by 9:30 AM on Wednesday of week 2. Students are welcome to finish the assignments ahead of the scheduled deadline, but no late submission is allowed.

In-class Labs

All labs are to be done individually, in class, with the assistance of the instructor and TAs. Each assignment will be given near the beginning of a class and must be completed before the due time. Some of the labs allow for late submission till midnight with late penalty, but no submission is allowed beyond the lab day. To receive full credits, a programming assignment must pass all given test cases, but partial credits will be awarded based on the understanding of the material demonstrated by the student’s code.

Team Projects

All projects are team projects in this course. For each project, students must form a team of 2 members. Teams are responsible for dividing their workload and meeting offline for at least 2 times for each project. Documented meeting agenda and minutes have to be submitted as part of the deliverable. Students should select their teams by using the Groups tab under People, on the Canvas webpage.

Teams are responsible for dividing their workload. Except under extreme circumstances, all members of the team will receive the same grade for each project. One member of each team is designated the leader. The files for each project should be zipped up and uploaded by the team leader using Canvas before the due date. Projects must not be stored in a public folder. All project submissions must follow the provided file name requirements or risk a score of 0. If the project does not compile, the student will receive a score of 0.

Projects will be graded based on the following criteria:

  • Correctness: Finding the right answer
  • Formatting: Displaying the right answer according to instructions
  • Style and Documentation: Producing readable code with appropriate comments

Only project is allowed to submit late. Late submissions will lose equation points per day, including weekends and holidays. For example, -1 after 1 day, -2 after 2 days, -4 after 3 days … until 8+ days students will receive 0 score. Under no circumstances should any student disclose their code, or copy the code written by other students or from an outside source. Both students will receive 0 score on the disclosed/copied assignment.

Grading Rubrics

Code

Grading rubrics for code submission in terms of percentage:

100%:

  • Functionality: For assignments that have well-specified behavior, the code should be able to pass (or very nearly pass, e.g. there may be minor output formatting issues) automated unit testing of all required features. For open-ended assignments the code must be easy to run without modification and implement all of the required functionality.
  • Documentation: all functions are commented with appropriate doc strings. For open-ended assignments there is a README file discussing how to run the program and what it is supposed to do.
  • Style: the program exhibits effective modular design. The code does not have unnecessary cut and paste code or magic numbers. Variable and function names are sensibly chosen.

80%:

  • Functionality: For assignments that have well-specified behavior, the code should implement all of the required functionality. For this grade, it is possible that 10-20% of the functionality may be broken. For open-ended assignments it will be possible to get the code running with modest effort (i.e. it will not be as well documented as in a 5, but it isn’t too hard to intuit how the code works). For these types of assignments all required features must be present, however, some (10-20%) may not be functioning properly or otherwise poorly implemented.
  • Documentation: some functions are missing doc strings. Comments are fairly minimal.
  • Style: some aspects of the design of the program could be improved to reduce cut and paste code. Variable and function names are for the most part well-chosen.

60%:

  • Functionality: The code should implement almost all of the required features (it is okay if roughly 20% are not implemented). A significant portion, 30-50%, of the code may not work as it is supposed to.
  • Documentation: Docstrings are mostly absent For well-defined assignments the code does not run as it should based on the assignment spec. For open-ended assignments there may not be any indication of how to run the program, and it is not easy for a NINJA to figure out how the code works (a good test is if you have to e-mail someone to ask them how their code runs, they are probably at this level).
  • Style: the program design needs improvement. The code would be a lot cleaner if the author had done a better job thinking through the appropriate functional decomposition. The code has lots of cut and paste and magic numbers. Variable and function names are hard to interpret.

40%:

  • Functionality: the assignment is incomplete (~50% of the functionality is not implemented). The functionality that is implemented is not 100% correct.
  • Documentation: mostly absent.
  • Style: design is poor. Very little attention has been paid to choosing a sensible functional decomposition. Variable and function names are chosen almost arbitrarily.

20%:

  • Functionality: only minimal functionality is present.
  • Documentation: little or none.
  • Style: Code is not “readable”. Poor choice of variable and function names.

0%:

  • nothing turned in.

Notebook Assignments

Jupyter notebooks are the files you need to submit for labs and homework assignments.

100%:

Thorough engagement with each section of the reading. Each exercise has either been completed, or you have articulated a well-thought out set of questions for each of the problems you didn't answer. Points will be deducted from 100% for the following reasons:

  • Exercises are not filled out (either with a solution or a question)
  • The answer to the exercise does not demonstrate a good faith attempt to complete it.

Writing

Writing will be evaluated for clarity, concision, and comprehensiveness. The particular style that you should use will depend on the assignment and your audience. The bottom line is don't cut corners with writing in this class. Your ability to communicate what you have done is just as important as what you have done. Don't make the mistake of spending all of your time writing code, and then rush through the writing parts of the assignment. See below for some stylistic guidance.

  • Since the dawn of time, college students have been writing introductions that are too grandiose (and often false). Just get into it; you don't have to zoom in from space (and make stuff up). Write the abstract last and summarize the most important result.
  • The passive voice is a hoax. Please write in the first person (singular or plural).
  • Write in the present tense whenever possible. Some actions happen in the past, but all research exists in an eternal present: “Using data from BRFSS, they plot weight versus height and find that tall respondents are heavier, on average, than shorter respondents. Our results are consistent with this conclusion.”
  • When you edit, try to remove words.
  • Avoid using “significant” unless you mean “statistically significant;” a good alternative is “substantial.” Avoid using “correlation” unless you mean a coefficient of correlation. In general, there might be a “relationship” between variables and you might characterize it with a correlation.
  • “Trend” usually means something is changing in time; “pattern” is more general.
  • Provide indicators of logical flow. If I ask you to answer a set of question in your report, don't just paste the questions as your section headings. You should create your own document structure based on what makes sense for your project.
  • Explain your motivation. Avoid “We were interested” and “We wanted” as pseudo-motivation. And don't look at the camera; that is, don't use “because we were told to” as motivation, and avoid “for this project”.
  • When you refer to figures and tables, capitalize “Figure” and “Table.” Formal figures have a number and a caption, and they can float. Informal figures are part of the text flow. If a figure doesn't contain much information, summarize it in text.
  • Find an authorial voice that is casual enough to be engaging (without overdoing it).

Policy Statements

Course Schedule

The most up-to-date course schedule will be posted on course website schedule page: https://peilong.github.io/courses/cs121/schedule/. Students are responsible for checking the schedule regularly. Schedule page will include: 1) teaching topics for each meeting; 2) reading assignments for each day and 3) reminders on specific days.

Course Announcements & Discussion

All course announcements will be sent to your E-Town email accounts via Canvas Announcements. You are responsible for signing up for this service and checking your emails regularly.

I have created a Microsoft Teams channel (link) to facilitate course related discussion. Discussions are encouraged to be posted on the “QA” channel from Teams. Private instant messages can be sent directly to your recipient by search your recipient’s name on the “search” bar.

Attendance Policies

Attendance is expected of every student at every lecture. Students are responsible for all content covered in class as well as assigned book chapters. Due to their nature, pop quizzes cannot be made up.

Except in the case of documented emergencies, neither exams nor in-class labs can be made up afterwards. For excused absences, students must arrange to take the exam or do the lab before the normally scheduled time. Arrangements must be made with the instructor at least two weeks prior to the scheduled time.

Students are expected to maintain an attitude of respect at all times toward their colleagues, the equipment, and the instructor. Cell phones and similar devices is prohibited from using during lecturing time. Students who use offensive language, misuse computing facilities, or are otherwise disruptive of the classroom will be asked to leave.

Statement on School Closure

In the event that classes do not meet because Elizabethtown College is closed or delayed due to inclement weather or some other emergency, the slides that would have been covered during the missed classes will be posted through Canvas. Students are expected to do the assigned reading, review the slides, and e-mail the instructor with any questions. There will also be an opportunity to ask questions about the material when classes resume.

If a scheduled exam or lab is missed, it will normally be made up on the day that classes resume. If the College is closed on a day when a project is due, the project due date will also normally be extended until the day when classes resume. If circumstances render either of these makeup policies unreasonable, the instructor will send an e-mail explaining an alternative makeup opportunity to each student’s Elizabethtown e-mail account.

Statement on Plagiarism

Check out the up-to-date statement from: Elizabethtown College Catalog, “Academic Judicial System”

Statement on the Use of ChatGPT and Generative AI Tools

To maintain course integrity and ensure equal opportunity for all students, submissions generated by artificial intelligence (AI) systems, including ChatGPT, Bing Chat, Claude, Google Bard, or similar tools, are not allowed for classwork or assessments. Such AI usage diminishes the development of critical skills vital for academic success. While students can use AI for research and idea generation, all submitted work must be their original writing. It’s essential to recognize both the advantages and limitations of AI in learning and research. AI suggestions aren’t always accurate, so students should assess AI outputs critically. Breaching this guideline results in academic misconduct. Seek clarification if uncertain about AI usage in assignments.

Statement on Disability

Full statement can be found at: Course Syllabus on Disability Services, Religious Observances, and COVID related expectations.

Diversity and Inclusivity Statement

I consider this classroom to be a place where you will be treated with respect, and I welcome individuals of all ages, backgrounds, beliefs, ethnicities, genders, gender identities, gender expressions, national origins, religious affiliations, sexual orientations, ability - and other visible and non-visible differences. All members of this class are expected to contribute to a respectful, welcoming and inclusive environment for every other member of the class.

Software

Skulpt

An online Python interpreter for quick typing and note-taking. Available at: https://skulpt.org/using.html

CS 121 Software

Anaconda Individual

The Python packages and environment that you need to install on your computer to execute Python programs.

Visual Studio Code

Our Integrated Development Environment (IDE) for writing Python scripts.

The installation guide for both software is provided on zyBook Chapter 1.6: Installing CS121 Software Tools.

Download Anaconda from: https://www.anaconda.com/products/individual Download VS Code from: https://code.visualstudio.com/download

Note:

All the aforementioned software are available on the computers in the Esbenshade 281, Hoover 108 and Nicarry 208 computer laboratories and in the Computer Science commons area (E284).

Archived from Peilong/Peilong.github.io@cd0051b (2023-08-20).