1. Engineering
  2. Computer Science
  3. for java i need to write a program about reading...

Question: for java i need to write a program about reading...

Question details

For java

I need to write a program about reading test result

I want to ask two part of them

The input to the program is an ASCIIDataFile. The first line contains the course name (String), the second line contains the test name (String). Following that is the number of questi ons in the test (int) and, for each question on the test the correct answer (char: A, B, C or D). Then, for each student in the course, there is the students student number (String) and name (string) followed by four lines (corresponding to answers A, B, C and D) with one character per questi on (char: o for seratched and x for not scratched). The data (with one student) might look like: COSC 1PO3 Term Test 0 0 0 0 0 0 0 where the cosc 1P03 Term Test has 5 questions whose correct answers are : 1:A, 2:B, 3:C, 4:D and 5:A. Student 111111: Fred Flintstone scratche d off A on question 1; C and D on question 2; C and D on question 3; A, B, C and D on question 4 and A, B and C on question 5. The students responses are marked in the following way. Each question has a maximum value of3. If the student did not select the correct answer, s/he is awarded 0 for the

for each question on the test the correct answer (char: A, B, C or D).

&followed by four lines (corresponding to answers A, B, C and D) with one character per question (char: O for scratched and X for not scratched).

How to write it in public such as String courseName; String testName, etc

Solution by an expert tutor
Blurred Solution
This question has been solved
Subscribe to see this solution