lease provide JAVA source code for following assignment. Please attach proper comments and read the full requirements. The local Driver’s License Office has asked you to write a program that grades the written portion of the driver’s license test The test has 20 multiple choice questions. Here are the correct answers: B D A A C A B A C D B C D A D C C D D A A student must correctly answer 15 of the 20 questions to pass the exam. Write a class named Drivertest that holds the correct answers to the test in an array field. The class should also have an array field that holds the student’s answers. The class should have the following methods: passed. Returns true if the student passed the test, or false if the student failed totalCorrect. Returns the total number of correctly answered questions totalIncorrect. Returns the total number of incorrectly answered questions questionsMissed. An int array containing the question numbers of the questions that the student missed Demonstrate the class in a complete program that asks the user to enter a student’s answers, and then displays the results returned from the Drivertest class’s methods. Input Validation: Only accept the letters A, B, C, or D as answ
Please provide JAVA source code for following assignment. Please attach proper comments and read the full requirements.
The local Driver’s License Office has asked you to write a
-
B
-
D
-
A
-
A
-
C
-
A
-
B
-
A
-
C
-
D
-
B
-
C
-
D
-
A
-
D
-
C
-
C
-
D
-
D
-
A
A student must correctly answer 15 of the 20 questions to pass the exam.
Write a class named Drivertest that holds the correct answers to the test in an array field. The class should also have an array field that holds the student’s answers. The class should have the following methods:
-
passed. Returns true if the student passed the test, or false if the student failed
-
totalCorrect. Returns the total number of correctly answered questions
-
totalIncorrect. Returns the total number of incorrectly answered questions
-
questionsMissed. An int array containing the question numbers of the questions that the student missed
Demonstrate the class in a complete program that asks the user to enter a student’s answers, and then displays the results returned from the Drivertest class’s methods.
Input Validation: Only accept the letters A, B, C, or D as answers.
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 1 images