Please enable JavaScript to use CodeHS

AP Computer Science A (Nitro)

Lesson 2.4 Calling a Void Method

Description

In this lesson, students will take a deeper look into creating and calling the methods of a class. Methods are procedures that define and allow for control of the behavior of an object. Once an object is instantiated, the instance variables can be used across the different methods that are created. Students will also learn about procedural abstraction for methods that can be used without knowing all of the underlying details and code. This lesson corresponds with AP Computer Science A topic 2.3.


Objective

Students will be able to:

  • Create and call class methods
  • Call non-static void methods without parameters