Code In java Netbeans A University wishes to keep information on its students. The proposed Student class has the following instance variables: studentNo: String, studentName: String, dateOfBirth: Date, meritPoints: Integer. Merit Points represents the entry qualification achieved by a student, which is a number between 20 and 200. A class variable is also required, called noOfStudents, which will be incremented each time a Student instance is created. Write Java code to perform the following: Q) Show the declaration of the Student class, including any setter and getter methods. Declare two constructors as follows; both constructors should increment the class variable appropriately: a. The first is a default constructor that has no parameters and sets the instance variables to either "not known" for the strings, 20 for the integer and your date of birth for the date (assume there is a Date constructor that accepts dates in a string format). b. The second takes 4 parameters, one for each of the instance variables.

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter4: More Object Concepts
Section: Chapter Questions
Problem 11PE
icon
Related questions
Question

Code In java Netbeans

A University wishes to keep information on its students. The proposed Student class has the following instance variables: studentNo: String, studentName: String, dateOfBirth: Date, meritPoints: Integer. Merit Points represents the entry qualification achieved by a student, which is a number between 20 and 200. A class variable is also required, called noOfStudents, which will be incremented each time a Student instance is created. Write Java code to perform the following:


Q) Show the declaration of the Student class, including any setter and getter methods. Declare two constructors as follows; both constructors should increment the class variable appropriately:

a. The first is a default constructor that has no parameters and sets the instance variables to either "not known" for the strings, 20 for the integer and your date of birth for the date (assume there is a Date constructor that accepts dates in a string format).

b. The second takes 4 parameters, one for each of the instance variables.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Developing computer interface
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,