AP Computer Science A

Advanced Placement Computer Science A focusing on Java programming and object-oriented design.

Practical Applications

Building a Simple Address Book

Creating Useful Projects with Java

One practical way to combine everything you've learned is to build a simple address book app. You'll use variables, classes, arrays or ArrayLists, and control structures.

Steps to Build

  1. Create a Contact class with fields for name, phone, and email.
  2. Use an ArrayList<Contact> to store multiple contacts.
  3. Add methods to add, remove, and display contacts.
  4. Use loops and conditionals to interact with users.
public class Contact {
  String name, phone, email;
  // constructor and methods here
}

This project mirrors what real developers do when making productivity tools or managing information.

Expanding on the Idea

  • Add search features.
  • Allow saving and loading contacts from a file.

Examples

  • Implementing a class to store and display friend information.

  • Providing options to add or remove contacts from the address book.