Question
***In Java*** Write a class named Student... in this class it should have fields named for their 1. GPA 2. ID number 3. Number of
***In Java***
Write a class named "Student"... in this class it should have fields named for their 1. GPA 2. ID number 3. Number of classes taken 4. Days without a class scheduled.
Add a public static main method to the class...It should ask the user for how many students are currently enrolled at the school. Then have the program create an array of Students equal to that size and create student instances for it. For each instance, ask the user for 1. GPA 2. ID number 3. Number of classes taken 4. Days without a class scheduled(should be 0 or 1). After this, add up the total number of days with a class scheduled (#4) After this is completed, write a loop through the student instances in your array and for each, print out their information for #1, #2, and #3. and for the last part, print out the percentage of the total number of days students don't have a class.(essentially add the students up that have a day off from class and divide by the total)
edit: I don't really understand this at all either. (hence why I asked :P ) anyway... I would say do something similar to this.
Step 1: Ask User how many students are enrolled at school
Step 2: create An array of students equal to that number the user entered
Step 3. In the class define four fields (for 1, 2, 3, 4)
Step 4: ask user for information for the four fields (just put like 3 or 4 students, something small)
Step 5: Just print out the results (Example: Student 1: 3.0 / 42434 / 5 / 1 ..Student 2: ..etc) [and maybe try to turn the 4th part into a percentage of how many students are missing a day, if not, no biggie]
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started