Please enable JavaScript to use CodeHS

AP Computer Science A (Mocha)

Lesson 3.2 Methods and Parameters

Description

In this lesson, students are introduced to parameters. Parameters act as inputs for methods. Imagine methods as boxes, with parameters being the items placed inside these boxes. By using parameters, methods become more versatile, allowing them to handle different versions of the same problem.


Objective

Students will be able to:

  • Explore code examples that include methods and parameters
  • Write methods that take parameters as inputs
  • Apply knowledge of methods and parameters to solve coding exercises