CSC 175 - Intermediate Programming

Dr. D. Chays

  • 4/16 Exercises: List Exercises
  • Slides for Chapter 5 (Linked Lists) part A and part B. This corresponds to chapter 4 of previous edition.
  • Examples for Chapter 5 (Linked Lists)
  • Video Inventory Example (jar file)
  • examples of Dialog Boxes and File I/O
  • 4/18 Exercise (ArrayList): Refer to Chapter 5 examples (second section on ArrayList, e.g. GroceryList, ArrayListComputations). Create Bank3 which implements BankInterface, and stores the accounts in an ArrayList of Account objects.
  • Exercise (reading from text file): Insert the missing code in ATM.java which calls helper method readOneAccountFrom in InputManager (note for helper method readOneAccountFrom: data types of accountNum and balance need to be changed to be consistent with your banking program). You will also need to create the input file which your ATM's main method opens and reads from, e.g. something like this (format: name,id,balance-in-cents):
    Ted Murphy,72354,10256
    Jane Smith,69713,4000
    Edward Demsey,93757,75932
    
    or something like this (format: name,id,dollars,cents):
    Ted Murphy,72354,102,56
    Jane Smith,69713,40,0
    Edward Demsey,93757,759,32
    
  • Thursday 4/25 Exercises: More list Exercises
  • HW5 Solution to Exercises 1-3
  • HW5 Alternate Solutions to Exercises 1-3
  • UP TO HERE FOR 4/30 EXAM

  • Game enhanced by Nicholas Miceli to include graphics: ExploreGUI.jar
  • Slides for Chapter 7 (Stacks) part A and part B. This corresponds to chapter 6 of previous edition.
  • Examples for Chapter 7 (Stacks)
  • More Stack Examples: 1) merging 2 stacks of Integers into a third stack; attached jar file contains StackTest2 and StackTest3 and 2) using a stack to check whether or not a string is a palindrome
  • 5/2: Stack exercises: Focus on Exercise 2: Create a class of infix calculators with 2 methods: convertToPostfix and evaluatePostfix.
    // Sample driver code (alternatively, infixExp and postfixExp can be attributes of a Calculator class)
    String postfixExp = convertToPostfix(infixExp); 
    int result = evaluatePostfix(postfixExp);
    

  • Slides for Chapter 8 (Queues) part A and part B. This corresponds to chapter 7 of previous edition.
  • Examples for Chapter 8 (Queues)
  • Queue Examples (zip file)
  • 5/7 Queue exercises: QueueTest2 (merge 2 queues of Integers into a third queue)
  • Examples of programs that use both a stack and a queue.
  • Slides for Chapter on Class relationships (chapter 9 of 2nd edition; chapter 8 of previous edition)
  • Examples for Chapter on Class relationships (chapter 9 of 2nd or 3rd edition; chapter 8 of previous edition) (zip file)
  • Polymorphism Demo - see 3/1 lab exercise above (which has the Java code demo'd in class).
  • Slides for Chapter on Algorithm Efficiency and Sorting (chapter 10 of 2nd or 3rd edition; chapter 9 of previous edition)
  • Bubblesort dance
  • Big O Cheat Sheet
  • Slides for Chapter on Trees (chapter 11 of 2nd or 3rd edition; chapter 10 of previous edition)

  • Additional useful data structures: sets and maps

  • UP TO HERE FOR FINAL 5/14
  • Version Control Demo by former TA Brian

    Submit final project via bitbucket and email (zip/jar) OR share via Google drive (drive.google.com).


  • Networking example: client-server program in Java (download KnockKnockServer, KnockKnockClient, KnockKnockProtocol; to test on same machine, run main of KnockKnockServer in one window and main of KnockKnockClient in another)
  • Example program that saves an object to a file and restores it (useful for saving a state that you wish to go back to when you run your program again; see hw6 extra credit): TestSavingObjectToFile.java uses BioData.java

    [Back to the Class's Home Page]