Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

i want to figure out how these sub method works -courseID: int -courseCode: String -courseName: String -courseCapacity: int -numberStudents: int -room: Room -students: Student[] -waitListCount:

image text in transcribedi want to figure out how these sub method works

image text in transcribedimage text in transcribedimage text in transcribed

-courseID: int -courseCode: String -courseName: String -courseCapacity: int -numberStudents: int -room: Room -students: Student[] -waitListCount: int +Course (ID: int, code: String, name: String, room: Room) +getBuildingName(): String +getCampus (): String +getCourseID(): int +getCourseCode (): String +getNumber Students(): int +getStudents(): Student[] (Returns array of registered students) tisInCourseAlready (student: Student): boolean +isSpaceLeftInCourse (): boolean +registerStudent (student: Student): int +toString(): String +get Students (): Student[] Returns an array of Students that are registered in the course. Note that this is a subarray of the students array. tisInCourseAlready (student: Student): boolean Returns true if student is already registered for the course, false otherwise. +isSpaceLeftInCourse () : boolean Returns true if there is space left in the course (e.g. number of students is less than the course capacity). Room.java Student.java New Building.java Course.java 1. import java.util.*; 3. public class course{ private int courseID; private String courseCode; private String courseName; private int CourseCapacity; private int numberStudents; private Room room; private Student[] students; private int waitListCount; Dovou public Course(int ID, String code, String name, Room room) { this.courseID = ID; this.courseCode = code; this.courseName = name; this.room = room; COMPILER STACK TRACE None PROGRAM EXECUTION STACK TRACE None INPUT OF THE TEST CASE 1 7/Course: int cID = 24320656; String cCode = "DATA 2110"; String cName = "Tricky Data Structures": inmine //Building: string bName = "Patrick vanGuard"; int bFloors = 27; String bCampus = "Georgetown"; 12 //Room: int rNumber = 328; int rCapacity = 120; 15 1/Student: 16 int sID = 418036; 17 String sFirst = "Serena" YOUR CODE'S OUTPUT 1 [ERROR ] exception in unit test code! ava Lang Muli intervention 2

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

Databases Demystified

Authors: Andrew Oppel

1st Edition

0072253649, 9780072253641

Students also viewed these Databases questions

Question

=+ What are the information and consultation requirements?

Answered: 1 week ago

Question

=+ Should the MNE belong (why, why not)?

Answered: 1 week ago