Académique Documents
Professionnel Documents
Culture Documents
I. AP Computer Science
About the AP Computer Science Exam
Types, Variables, & Arithmetic Operators
Equality, Relational, & Logical Operators
Input, Output, & Errors
Conditional Statements
Loops
Strings
Arrays
Classes & Objects
Inheritance & Polymorphism
Lists
Numeric Wrapper Classes & Mathematical Functions
Algorithms: Iteration
Algorithms: Recursion
Algorithms: Sorting
Algorithms: Searching
Program Design & Development
Standard Classes & Interfaces
II. AP Test Preparation
Multiple Choice Question Tips & Practice
Free Response Question Tips & Practice
The GridWorld Study
Multiple Choice Questions About GridWorld
Free Response Questions About GridWorld
Final Tips for Taking the Exam
Glossary of Terms to Know
17:11
23:20
22:34
24:07
28:00
32:29
42:20
47:02
47:33
31:30
33:15
23:14
25:43
27:30
29:42
32:37
29:29
32:53
55:47
40:55
54:18
41:00
39:31
27:38
36:31
I. AP Computer Science
About the AP Computer Science Exam
Intro
Roadmap
Java Editor
The AP Computer Science Exam
When It's Administered
Final Score
College Credit
Format of AP Exam Questions
Two Sections
Section 1
Section 2
Scoring
Multiple Choice Questions
Example
Check Answer in Java Editor
Keep in Mind
Multiple Choice, Multiple Answers
Evaluate Each Roman Numeral Separately
Example Multiple Choice Question
Java Editor
Free Response Questions
Example
Java Editor
AP Java Subset
What It Is
Primitive Types
Arithmetic Operators
Assignment Operator
Combined Arithmetic / Assignment Operators
Increment / Decrement Operators
Relational Operators
Logical Operators
Numeric Casts
Numeric Wrapper Classes
Math Library Methods
String Operations
User Input
Output
17:11
0:00
0:16
0:45
1:30
1:31
1:49
2:08
2:20
2:26
2:31
2:40
3:23
3:57
4:04
5:06
6:21
6:58
7:08
7:34
8:35
12:25
12:40
14:35
17:06
17:37
18:49
19:11
19:46
19:51
20:13
20:36
21:06
21:44
22:39
23:08
23:50
25:33
27:17
Program Invocation
Arrays
Lists
Control Structures
Methods
Classes
Inheritance
Exceptions
Tips for Taking the Exam
Before the Exam
During the Exam
Summary
Types, Variables, & Arithmetic Operators
Intro
Roadmap
Primitive Data Types
Int
Double
Boolean
Variables
Declaring a Variable
Assigning a Value
Declaring and Assigning on the Same Line
Casting
Mixing Types
Automatic Casting
Find Variables - Constants
Final Variables
Constants Written in All Capitals
Arithmetic Operators
Five Arithmetic Operators
Result Depends on Type of Operands
Assignment Operators
Compound Assignment Operators
Examples
Increment / Decrement Operators
Add 1 (++)
Subtracts 1 (--)
Summary
Equality, Relational, & Logical Operators
Intro
Roadmap
28:13
29:06
29:52
30:47
31:27
32:10
33:09
34:22
34:55
35:04
36:58
39:27
23:20
0:00
0:11
0:37
1:48
2:42
3:53
4:04
4:16
6:01
6:36
7:00
7:10
8:31
9:21
9:40
10:43
11:59
12:10
13:49
14:59
15:13
15:43
17:08
17:37
18:25
21:41
22:34
0:00
0:11
1:09
1:15
2:25
2:40
3:44
3:53
4:18
4:50
5:19
5:43
6:23
6:41
7:16
7:30
8:05
8:47
10:03
10:32
12:29
13:53
14:04
14:29
15:28
15:38
17:30
20:26
24:07
0:00
0:11
0:42
0:54
2:50
3:20
4:38
5:06
5:45
6:16
6:40
7:04
11:10
11:23
11:49
12:39
13:48
14:43
16:25
16:33
17:18
19:40
22:21
28:00
0:00
0:09
0:55
1:40
2:42
2:59
3:06
4:46
6:02
6:34
7:13
7:28
7:56
9:28
10:24
13:14
15:45
18:54
19:37
22:44
27:03
32:29
0:00
0:07
0:53
1:03
1:21
1:32
2:16
2:55
4:57
5:53
8:00
9:04
10:30
10:41
12:43
14:18
14:42
16:32
19:06
19:33
20:47
22:36
22:51
23:29
24:30
25:03
26:21
28:01
30:56
42:20
0:00
0:25
1:27
1:38
2:11
2:53
3:27
4:24
5:56
7:03
7:37
8:26
10:00
10:11
10:48
11:25
13:05
14:16
16:04
16:37
17:08
21:40
21:49
22:14
22:46
25:38
25:53
27:27
28:15
30:34
30:59
31:08
31:27
32:41
34:02
36:04
36:12
36:26
37:27
38:36
38:53
39:08
39:28
40:43
47:02
0:00
0:14
0:49
0:55
1:10
2:15
5:12
5:39
7:26
9:12
9:45
12:23
15:35
15:42
17:19
19:25
19:37
21:03
23:05
23:33
25:15
28:13
30:09
30:15
33:40
34:06
36:02
36:12
38:42
39:24
42:23
43:17
43:42
45:00
47:33
0:00
0:46
2:03
2:17
2:34
3:43
5:34
7:11
7:44
8:45
9:08
10:19
12:48
13:10
13:50
14:43
16:21
16:37
16:49
17:25
18:19
19:31
20:00
20:58
21:08
21:18
21:28
21:36
24:47
25:35
26:24
27:15
27:26
27:59
30:19
34:00
36:17
37:28
37:53
38:51
39:39
40:19
40:45
43:52
44:19
45:00
31:30
0:00
0:42
1:14
1:56
2:07
3:08
3:36
4:44
6:05
7:06
7:17
8:59
10:24
11:31
12:41
14:35
15:59
20:19
20:34
22:33
25:13
25:27
Summary
Lists
Intro
Roadmap
Lists
Wrapper Classes
The List Interface
Cannot Instantiate a List
The ArrayList Class
The Way It Works
The ArrayList Class
Primary Methods Needed To Use for ArraryList
Code Examples
The LinkedList Class
To Instantiate a LinkedList
Code Example
ArrayList vs. LinkedList
Internal Storage Implementation of ArrayList
Internal Storage Implementation of LinkedList
Pros/Cons of Each
Summary
Numeric Wrapper Classes & Mathematical Functions
Intro
Roadmap
Numeric Wrapper Classes
To Get Around Storing Limitation
Setting and Getting Values
Double Class
Comparing Values
Equals Method
Comparing Values
CompareTo Method: Integer Class
CompareTo Method: Double Class
Minimum and Maximum Values
Integer Class: Publib Static Final
Double Class
Automatic Conversion
Autoboxing
Example
Get Method
The Math Class
Math.E
29:26
33:15
0:00
0:16
0:52
1:10
2:37
3:26
5:01
7:45
8:34
8:53
16:26
21:01
21:59
24:05
25:25
25:35
26:01
26:23
32:10
23:14
0:00
0:11
0:42
1:19
2:30
3:57
5:07
5:22
7:16
7:29
9:24
10:28
10:56
12:19
12:53
13:12
13:36
14:52
15:59
16:18
Math.PI
Example
The Math Class
Working With Random Numbers
Example
Summary
Algorithms: Iteration
Intro
Roadmap
Iteration
Iteration Defined
For Loop / While Loop
Example
Iteration
Two-Dimensional Range
Using Two Nested While Loops
Finding Minimum and Maximum Values
Finding Minimum and Maximum Values Examples
Finding Minimum and Maximum Values Example
Inserting in Order
Inserting in Order Code
Loop Invariants
Example
Summary
Algorithms: Recursion
Intro
Roadmap
Recursion
Calculating Factorials
n! and How It's Defined
Recursive Implementation of the Factorial Function in Java
Calculating Factorials
Calculate 4!
Factorial Function in Java
Calculating Fibonacci Numbers
Fibonacci Numbers Defined
Recursive Implementation
Implementation in Java
Calculating Fibonacci Numbers
Calculate Fibonacci(4)
Fibonacci in Java
Other Recursive Functions
16:25
16:34
17:07
18:42
19:47
22:14
25:43
0:00
0:13
0:36
0:39
0:50
1:11
3:11
3:19
5:00
5:54
7:50
12:52
15:19
17:42
21:53
23:17
24:37
27:30
0:00
0:09
0:44
2:49
3:01
3:34
4:34
4:35
7:22
9:19
9:30
10:33
10:44
11:28
11:29
14:59
17:35
21:32
21:33
22:29
23:49
25:15
26:41
29:42
0:00
0:08
0:55
1:05
1:14
3:49
3:58
5:05
7:46
10:57
13:02
15:14
16:15
18:03
20:34
21:36
23:35
27:19
32:37
0:00
0:08
0:40
2:22
2:29
4:24
6:28
8:51
12:03
16:59
20:38
20:53
25:34
28:16
29:14
31:14
29:29
0:00
0:41
1:20
1:35
2:26
4:43
5:56
6:10
6:51
8:47
8:58
10:33
11:36
15:03
15:23
19:28
19:35
19:44
20:53
21:00
24:19
24:29
25:25
27:27
32:53
0:00
0:13
1:46
1:57
2:06
2:16
2:28
3:19
3:32
3:51
4:28
5:05
6:14
6:35
6:50
7:06
String
Methods
What Else To Know
Math
Methods
What Else To Know
List
Methods
ArrayList
What Else To Know
Test-Taking Tips
Summary
II. AP Test Preparation
Multiple Choice Question Tips & Practice
Intro
Roadmap
AP Computer Science Exam Structure
Two Sections
Contribution to Score
Multiple Choice Strategies and Tips
Example Question 1
Example Question 2
Example Question 3
Example Question 4
Example Question 5
Example Question 6
Example Question 7
Example Question 8
Example Question 9
Example Question 10
Summary
Free Response Question Tips & Practice
Intro
Roadmap
AP Computer Science Exam Structure
Two Sections
Contribution to Score
Free Response Strategies and Tips
Free Response Strategies and Tips Continued
Free Response Strategies and Tips Continued
Free Response Strategies and Tips Continued
Free Response Strategies and Tips Continued
8:16
8:40
12:10
15:24
15:36
18:13
20:02
20:30
22:45
23:27
26:05
29:47
55:47
0:00
0:23
1:32
1:40
3:35
4:50
9:07
13:34
16:12
21:44
26:41
34:12
39:41
42:09
46:31
50:35
54:49
40:55
0:00
0:27
1:15
1:20
2:09
3:23
6:17
10:22
13:00
15:42
17:41
18:30
19:29
19:56
21:48
24:14
25:36
26:28
27:04
27:33
28:50
31:06
31:49
34:06
34:48
39:52
54:18
0:00
0:19
0:51
1:00
3:14
5:16
8:00
8:06
8:52
9:22
9:57
10:21
11:36
12:32
13:13
13:31
15:25
15:34
16:21
16:58
17:05
17:35
18:16
18:41
18:50
20:34
20:42
20:52
21:00
22:16
22:23
22:13
23:26
23:44
23:55
24:21
25:02
25:24
25:37
25:44
26:27
27:02
27:31
27:38
27:46
28:09
28:27
28:40
28:51
30:03
30:17
31:24
31:46
31:58
32:35
32:51
33:53
34:34
36:38
38:53
40:49
41:00
41:20
41:55
42:16
43:41
44:03
Next Step
3rd Step
Last Step in Act Method
ChameleonCritter Class
Redefines Some Characteristics of Critter Class
Another Difference
Summary
Multiple Choice Questions About GridWorld
Intro
Roadmap
Multiple Choice Strategies and Tips
Structure
Points Worth
Some Strategies and Tips
No Penalty for Wrong Answer
Some Strategies and Tips Specifically on GridWorld Questions
Some Strategies and Tips Specifically on GridWorld Questions
GridWorld Testable APIs and Code
Testable APIs
Testable Code
Example Question 1
Example Question 2
Example Question 3
Example Question 4
Example Question 5
Summary
Free Response Questions About GridWorld
Intro
Roadmap
Free Response Strategies and Tips
Format
Points
Quick Reference Guide
Not Required to Do in Order
Multiple Parts
All Answers Must Be Written in Java
Partially Correct Solutions Can Be Awarded Partial Credit
Write Neatly
Don't Waste Time
GridWorld Testable APIs and Code
Testable APIs
Testable Code
45:38
47:01
48:33
49:00
49:26
51:02
52:25
41:00
0:00
0:16
0:45
0:49
1:47
3:29
6:10
6:29
9:37
13:17
13:25
13:47
14:32
17:11
22:53
26:17
34:11
39:47
39:31
0:00
0:14
0:49
0:56
1:18
1:49
2:48
3:33
5:00
7:49
10:40
12:52
14:55
15:05
15:53
16:37
16:41
17:34
18:23
18:54
20:00
21:08
21:56
22:59
23:59
24:28
25:08
25:55
28:44
31:54
32:19
35:30
35:47
38:34
27:38
0:00
0:10
0:46
0:49
1:24
2:15
2:38
3:42
4:00
4:57
5:54
8:32
10:33
13:09
14:49
15:20
15:39
15:54
16:19
18:47
22:00
24:23
Summary
Glossary of Terms to Know
Intro
Roadmap
Abstract Class
Array
Casting
Class
Conditional Statement
Constructor
Escape Sequence
Exception
Final Variable
Inheritance
Instance
Interface
Iteration
List
Logical Operator
Loop
Loop Invariant
Method
Numeric Wrapper Class
Overloading
Polymorphism
Primitive Data Type
Public and Private
Random
Recursion
Return Type
Searching
Signature
Sorting
Static
String
Subclass and Superclass
Glossary
26:44
36:31
0:00
0:16
1:28
2:29
3:43
4:39
5:35
6:28
7:18
8:24
8:59
10:19
11:36
12:33
13:08
14:05
15:11
16:20
17:06
17:30
18:55
20:38
21:10
23:22
24:06
25:03
27:07
28:08
28:59
30:14
30:51
32:40
33:37
34:30
35:37