AP® Computer Science A glossary

Object class

Also called: Object

Course: AP® Computer Science A Shows up in: Unit 1: Using Objects and Methods

The class at the top of every Java class hierarchy: all classes are subclasses of Object.

Appears in the course and exam description (CED): 1.12.A.31.15.A.5

Because every class is a subclass of Object, every object can use the behaviors Object defines, such as toString.

public class Coin
{
}

// in main
Coin c = new Coin();
System.out.println(c.equals(c));

Output:

true
Learn it properly, with a checkpoint 1.12 Objects: Instances of Classes

Related terms

Was this page helpful?

No names are ever shown, and every public comment is checked by us first. Please do not include personal details. To get a reply, email [email protected].

↑ Top

Enlarged view of the selected figure