007-002-015

Array of Objects

Medium

Problem Description

array of Objects

In this problem, you will create a program that defines a Student class, stores its objects in an array, and uses a loop to display each student's information along with the calculated average score to standard output.

Learning Objective: Understand how to store class objects in arrays for batch operations

Overview

Using an array of objects allows managing multiple instances of the same class together.

Specifications

  • Define Student class with name(String) and score(int) fields
  • Store 3 Student objects in an array
  • Display all student info and average score using a loop

Output Format

Alice: 85
Bob: 92
Charlie: 78
Average: 85.0

Ready to Try Running Code?

Log in to access the code editor and execute your solutions for this problem.

Don't have an account?