AP CSA (Java) Key Ideas

About this resource

AP CSA provides test-takers with the Java Quick Reference sheet during the exam, which contains key methods and their functions in an organized chart. The resource below sums up important concepts and mistakes that might be made despite access to the reference sheet. For example, it is common to forget to use .size() instead of .length for ArrayLists, or fall for a trick MCQ featuring a method that appears to but does not really modify the parameter variable. 

I wrote these notes for my own reference before tests I took for the class at school, as well as the ultimate AP exam. Things that I considered easier to understand and remember are not written in the notes. Days before the AP exam, these notes were pretty much all I needed to review before taking it. The resource is four pages in total, with units clearly labeled on the pages. Most bullets are conceptual reminders, and some are simply code snippets as a reminder for initialization syntax. 

Click between tabs to navigate to the desired unit.

Unit 1: Using Objects and Methods

  • IDE (Integrated development environment) provides tools to write, compile, and run code
  • compiler: converts human code to binary & detects errors
  • errors: syntax (language used incorrectly), logic, run-time (eg. Null Pointer), exception (not detected by compiler and interrupts execution, eg. Arithmetic Exception from division by 0 or IndexOutOfBoundsException)
  • escape: \” and \\ and \n
  • variable names: letters, digits, and underscores
    • no: beginning with digit, including spaces or reserved words
    • final goes directly before variable type (eg. public static final double WEIGHT = 49.9;)
  • casting: (double) (12 / 5) = 2.0 and (double 25 / 4 = 16.25
  • integer overflow wraps around (logic error)
  • rounding: (int) (x + 0.5) for positive; (int) (x – 0.5) for negative
  • procedural abstraction: tell method job without code

~

  • class methods and attributes are static (associated with class)
    • static methods call by ClassName.methodName();
    • bad practice to call static methods on objects (will run theoretically, but marked wrong on exam)
  • when in same class, can just call name
  • public attributes can directly call with period after class or object, private need getter/setters

~

  • example of using split: String[] fruits = sentence.split(“,”);
    • ^ does not remove whitespace
  • not on exam, but: .toUpperCase() & .toLowerCase()
  • cannot call method on null object
  • inheritance: public class Dog extends Animal {}
    • has attributes & methods from main class
    • subclasses may have own methods (override main)

Feel free to submit feedback (questions, suggestions, or areas to point out about this guide) through this form

This resource was published on The Sparchive on June 15, 2026.