AP Computer Science A FRQ Guide 2026 — All 4 Question Types with Java Examples
The AP Computer Science A free response section has 4 questions in 90 minutes. Each question focuses on one of four recurring topic areas: Methods & Control Structures, Classes, Arrays/ArrayLists, and 2D Arrays. This guide covers every question type with Java code templates, scoring rubrics, and the most common errors that cost points.
Exam Format Overview
| Section | Content | Time | Weight |
|---|---|---|---|
| Section I | 40 Multiple Choice Questions | 90 min | 50% |
| Section II | 4 Free Response Questions | 90 min | 50% |
Budget roughly 22 minutes per FRQ. The questions are independent — you can do them in any order. Most students find Q1 (methods) the most approachable and Q4 (2D arrays) the most time-consuming.
How FRQs Are Scored
Each FRQ is worth 9 points, for a total of 36 points. Points are awarded for specific correct elements of the solution — not holistically. This means:
- You can earn partial credit even with a wrong final answer
- Correct logic with a minor Java syntax error may still earn most points
- An algorithmically wrong solution with correct Java syntax earns very few points
Grading Penalty Rules
- Missing semicolons: penalized only once per response (not per occurrence)
- Array access out of bounds in an otherwise-correct loop: penalized once
- Using the wrong access modifier (public vs. private): not penalized if the logic is correct
- Returning void instead of the correct type: will lose the return-type point but not all points
- Calling a method with wrong number of arguments: loses that method-call point
Question 1 — Methods & Control Structures
Question 1 provides an existing class with some methods already written and asks you to write one or two additional methods using iteration (loops) and/or conditionals. You must use the given class's existing methods correctly.
Q1 Template Approach
Given: A class with methods like getScore(), getName(), isActive(). You're asked to write a method like getBestScore() or countActive().
- Always use the class's provided getter methods — do not access fields directly
- Prefer the enhanced for loop (
for (Type x : list)) over an index loop when you don't need the index - Check whether the question says to return a value or modify something
- If you need to find a maximum, initialize your variable to the first element, not to 0 or Integer.MIN_VALUE
Question 2 — Classes
Question 2 asks you to design a complete class from scratch. You are given specifications for instance variables, a constructor, and several methods. You must implement all of them correctly.
Class Design Checklist
- Declare private instance variables at the top
- Write the constructor — initialize all instance variables using the parameters
- Write getter and setter methods as specified
- Write any additional methods using
this(implicit) to access instance variables - Make sure every non-void method has a return statement
private; writing the constructor with the wrong parameter names (colliding with instance variable names without using this.); omitting the return statement in non-void methods.
Question 3 — Arrays & ArrayLists
Question 3 typically has two parts — one working with a 1D array and one working with an ArrayList. Common tasks: searching, filtering, removing elements, or traversing to compute a value.
Array vs ArrayList — Key Differences
| Operation | Array (int[]) | ArrayList (ArrayList<Integer>) |
|---|---|---|
| Access element | arr[i] | list.get(i) |
| Set element | arr[i] = val | list.set(i, val) |
| Length/size | arr.length | list.size() |
| Add element | Not possible (fixed size) | list.add(val) |
| Remove element | Not possible | list.remove(i) |
ArrayList Removal — The Index Trap
When removing elements from an ArrayList while iterating, you MUST iterate backwards (or adjust the index) to avoid skipping elements:
Question 4 — 2D Arrays
Question 4 involves a 2D array (an array of arrays). Common tasks: traversing all elements, summing a row/column, finding a maximum in a region, or comparing values across rows and columns.
2D Array Traversal Patterns
grid.length= number of rowsgrid[0].length= number of columns (assuming rectangular array)grid[row][col]— first index is row, second is column
Finding the Maximum in a 2D Array
Critical Java Rules for the FRQ
| Rule | Correct | Wrong |
|---|---|---|
| String comparison | s.equals("hello") | s == "hello" |
| String length | s.length() | s.length |
| Array length | arr.length | arr.length() |
| ArrayList size | list.size() | list.length |
| Null check | obj == null | obj.equals(null) |
| Integer division | (double) a / b for decimal | a / b truncates to int |
| Boolean return | return x > 0; | if (x > 0) return true; else return false; |
5 Most Common AP CS A FRQ Mistakes
In Java, == compares object references, not content.
"hello" == "hello" may be false even if both values are the same. Always use .equals() for String comparison. This is the single most common error on the CS A FRQ.
The most common: using
<= instead of < with array indices. For an array of length n, valid indices are 0 to n-1. for (int i = 0; i <= arr.length; i++) will throw an ArrayIndexOutOfBoundsException on the last iteration.
Removing elements from an ArrayList using a forward loop without index adjustment skips the element immediately after the removed one. Always iterate backwards, or adjust i-- after removal.
If all values in a list are negative, initializing max to 0 will return 0 instead of the actual maximum. Always initialize max/min to the first element of the list (
arr[0] or list.get(0)).
The FRQ often provides a class with private fields and public getters. You must use the getter methods (
student.getGrade()) rather than accessing the field directly (student.grade — this won't compile if the field is private, and even if it compiles in your test, the grader checks for correct method use).
Related Resources
- AP Computer Science A Score Calculator
- AP Computer Science A Score Curve 2026
- AP Computer Science A Practice Test -- 30 Questions