Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Given a Student class, create a class with following characteristics The class name should be ClassRoom . Private variable students to maintain the list of

Given a Student class, create a class with following characteristics

  • The class name should be ClassRoom.
  • Private variable students to maintain the list of Student objects.
  • Function addStudent with input parameter name (string) and rollNo(int) adds a new student in students list.
  • Method getAllStudents should return all the students in ClassRoom.

Input Jack

1

Jones

2

Marry

3

where,

  • First & Second line represent a students name and roll number. And so on.

Output

1 - Jack

2 - Jones

3 - Marry

Assume that,

  • Maximum students count can be 10.

(Use Java to work on this question please).

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Nested Relations And Complex Objects In Databases Lncs 361

Authors: Serge Abiteboul ,Patrick C. Fischer ,Hans-Jorg Schek

1st Edition

ISBN: 3540511717, 978-3540511717

More Books

Students also viewed these Databases questions

Question

Discuss maps, hash tables, and skip lists

Answered: 1 week ago

Question

10-9 How have social technologies changed e-commerce?

Answered: 1 week ago