AP CS Assignments
Assignments by week:
Fall Term:
Winter Term:
Spring Term:
Monday, September 17
Description
Scanners and Formatters
Homework
  • Read all of chapter 4 (pages 49-63) in Think Java.
  • Read the all of chapter 5 (pages 67-78) in Think Java. Most of this should be review, but pay attention to the sections on recursion.
Wednesday, September 19
Description
Discourse on the Method
Homework
Thursday, September 20
Description
Exceptions
Homework
  • Download the ScannerCalc.java starter file and the sample solution. The program reads lines of input containing simple numeric expressions (like "4 + 3") and calculates the result. You must use a Scanner to parse the input, and printf() to display the results. The program only needs to understand 2 operands and one operator (longer chains of input are errors). To run the solution, open the Terminal and type "java -jar " and then drag the solution JAR into your Terminal window. There should be a space between the "-jar" and the filename. Due Monday at the beginning of class.
  • Read all of chapter 7 (pages 105-117) in Think Java. This should largely be review. Hint: Section 7.6 has a nice chunk of code that you can model your ScannerCalc code on (a loop that checks for a certain type of input).
Friday, September 21
Description
ScannerCalc
Homework
  • Finish ScannerCalc lab, due at the start of next class. It should be beautifully commented with your name and ready to turn in. I'll go over how to submit it at the start of class.
  • Reminder, to zip up your project, execute a command like the following:

    (cd /path/to/project/folder && zip -r ~/Desktop/name_of_zip .)