Course Overview
Advanced topics in object-oriented programming, including project design, planning, and testing with milestones and checklists. Programming topics include text processing (StringBuilder, StringTokenizer), inheritance, polymorphism, abstract classes, interfaces, generic classes, exception handling, random-access files, serialization, and an introduction to basic data structures such as collection classes and linked lists.
Expected Background
Prerequisite: successful completion of CSC 142. You should be comfortable with Java basics, control flow, methods, arrays, and elementary object-oriented programming.
→ Take the CSC 141/142 diagnostic (online)
Feeling rusty on classes & objects? → Interactive Classes & Objects review (self-check, ungraded)
Textbook & Tools
Textbook: Tony Gaddis, Starting Out with Java: From Control Structures through Data Structures, 4th Edition (ISBN 978-0134787961). The 3rd Edition is also acceptable.
- Java (JDK) version specified in D2L.
- IntelliJ IDEA recommended (Eclipse, NetBeans, or jGRASP acceptable).
Slides & Schedule
| # | Date | Topic | Slides | Supporting Materials |
|---|---|---|---|---|
| 1 | Aug 25, 2026 | Introduction; review of Java/OOP; project design, planning, milestones, testing | Class01.pdf | CSC 141/142 diagnostic; Syllabus (PDF); Class code (.zip) |
| 2 | Sep 1, 2026 | Java/OOP review (classes, objects, references, arrays); project design, milestones, checklists, testing | Class02.pdf | Class code (.zip) — includes AccountFlawed.java (find the flaws!) |
| 3 | Sep 3, 2026 | Chapter 9: wrapper classes; Character class; String methods; StringBuilder; tokenizing | Class03.pdf | HW1 assigned (due Tue Sep 15, 11:59 PM, D2L) · Starter code (.zip); Gaddis Ch. 9; Class code (.zip) |
| 4 | Sep 8, 2026 | Chapter 9: tokenizing in depth (split with regex, StringTokenizer, Scanner); parsing tokens into numbers; CSV record to object | Class04.pdf | Class code (.zip) · HW1 due Tue Sep 15, 11:59 PM; Quiz 1 Thursday (Chapter 9) · try 2 practice examples first |
| 5 | Sep 10, 2026 | Chapter 9: integrated text-processing problems (sentence capitalizer, password verifier, phone formatter, word statistics, score file, Pokémon search); build-a-Pokédex mini-project (CSV → objects → GUI); bridge to Chapter 10 | Class05.pdf | Quiz 1 — answers & explanations posted · Class code (.zip) — includes scores.csv and pokemonName.csv · Pokédex mini-project starter (.zip) — parse pokemon_data.csv into objects, call the provided GUI, then send your pick to the Pokémon World |
| 6 | Sep 15, 2026 | Chapter 10: inheritance fundamentals; superclass/subclass relationships; the protected access modifier | Class06.pdf | Review: Pokédex capstone wrap-up · HW1 due tonight, 11:59 PM · Class code (.zip) — Pokemon.java/Eevee.java (protected fields) and a Vehicle/ElectricCar pair |
| 7 | Sep 17, 2026 | Chapter 10: superclass/subclass relationships continued — multi-level hierarchies, is-a vs has-a, protected in depth | Class07.pdf | Class code (.zip) — Jolteon extends Eevee extends Pokemon, Trainer (composition), and a fix-the-access-modifier exercise |
Assignments & Deadlines
| Assignment | Assigned | Due (D2L) | Points | Handout |
|---|---|---|---|---|
Homework 1 — Text Processing (Chapter 9: String, StringBuilder, Character, wrapper classes, tokenizing) | Thu Sep 3, 2026 | Tue Sep 15, 2026, 11:59 PM | 100 (6% of grade) | CSC240_Fall2026_HW1.pdf Starter code (.zip) |
Homework 1 — what is in it
- Q1 Text Analyzer (30 pts): classify the characters of a line (letters / digits / whitespace / other), count vowels and words, reverse it with
StringBuilder, and test for a palindrome —TextAnalyzer.java. - Q2 Word to Number (25 pts): convert a phoneword such as
1-800-Flowersto1-800-3569377one character at a time —Word2Number.java. - Q3 Gas Prices (45 pts): parse a CSV of weekly New York gasoline prices (2008–2018) with
split/StringTokenizerandDouble.parseDouble; compute yearly and monthly averages and the highest/lowest price —GasPrices.java.
Everything you need is in Class 3 (Chapter 9). The handout has the exact output formats, sample runs, self-check values and a submission checklist.
Data file for Q3: CSC240_HW1_gas_prices.csv. The template downloads it automatically from this website; if the download fails on your computer (no network, or an older JDK), the program reads the copy of gas_prices.csv that is inside the starter zip — keep that file in the folder you run the program from (in IntelliJ, the project root). Either way, do not modify getData().
How to submit
- Finish the three files from the starter zip:
TextAnalyzer.java,Word2Number.java,GasPrices.java. Put your name in the header comment of each file, and do not change any of the existing template code. - Make sure all three files compile and match the sample runs in the handout. Run through the checklist on the last page of the handout.
- Compress the three
.javafiles into a single ZIP namedLastName_FirstName_HW1.zip(e.g.Lovelace_Ada_HW1.zip). Do not zip the whole IntelliJ project, and do not submit.classfiles, screenshots, or Word documents. - Upload the ZIP to D2L → CSC 240 → Assignments → Homework 1 before Tuesday, September 15, 2026, 11:59 PM. You may resubmit as many times as you like before the deadline; only the last submission is graded.
- Check the D2L confirmation email. The D2L timestamp is authoritative.
Tutorials & Supporting Materials
- Example code from each class is linked in the schedule above (per-class .zip, open in IntelliJ). All-in-one: CSC240_code.zip
- CSC 141/142 Diagnostic — online submission
- Diagnostic reference answers (posted after class)
- Install IntelliJ IDEA Community Edition: jetbrains.com/idea