[Solved] Student Grade Task 1 and 2

30 $

File Name: Student_Grade_Task_1_and_2.zip
File Size: 244.92 KB

SKU: [Solved] Student Grade Task 1 and 2 Category: Tag:

Or Upload Your Assignment Here:


The given program ,(ProjectOld File), performs statistical analysis of scores for a class of students by printing student scores and calculate the lowest, highest, & average score of each quiz for every student. The class may have up to 40 students. There are five quizzes during the term. Each student is identified by a four-digit student ID number.The new project(Project Main) must be created on top of this project(ProjectOld File)Task I:create a separate serialized file using ObjectOutputStream for each student. File should contain student’s score and statistics for entire class. Using debug mode (with Debug flag) print the contents of the serialized file.Class StudentGradeClass StatisticsClass StudentSteps for this task:Write a serialized file for each student.Create a class – StudentGrade implements SerializableInstance variablesStudent <– One studentStatisticsprint() –prints properties of both Student and Statistics.(complete this given Class:package db;import java.io.*;public class StudentGrade implements Serializable{private Student stu;private Statistics stat;public StudentGrade(Student stu, Statistics stat) {this.stu = stu;this.stat = stat;}void print(boolean debug){if(debug==true){//call the print methods of classes used for instance variables.}}//add any other methods as you see fit.}FileIO Class-WriteStudentGradetoDisk(StudentGrade a1)//Write the object to disk.//Use studentid in StudentGrade as filename.dat – for e.g. “1234.dat”ReadStudentGradetoDisk(String filename)Driver Class-Create an array of StudentGrades – and write to diskFileio f1 = new FileIO();StudentGrade a1[] = new StudentGrade[40];LoopBuild StudentGrade objects using StudentGrade constructor.f1.WriteStudentGradetoDisk(a1[i]);End Loopread each file – print the score.Using debug mode (with Debug flag) print the contents of the serialized file.Create and implement an interface to:Print student statistics.Print scores for a given student id.implement the Debug flag globallyUse an abstract class to implement all the methods declared in an interface.When printing a serialized file it should look like this:Stud Q1 Q2 Q3 Q4 Q51234 78 83 87 91 86High Score 78 89 93 91 86Low Score 67 77 84 82 71Average 73.4 83.0 88.2 86.6 78.6a) naming convention for each filename.studentid.ser or studentid.datb) method for writing and reading serialized file should be in FileIO or Util.c) When implementing Serialization – implement Serializable interface in following classes– StudentGrade– Student– StatisticsDesigning main()1. Instantiate StudentGrade.File has already been read (n records read (upto 40)).2. Prompt a user – to deliver all grades – (n serialized files are written to disk).When you serialize – good idea to print before serializing and after serializing – good way to confirm – with DEBUG flag turned on3. Testing part 1 –Different # of records in the file.Boundary condition –Up to 40 records41 records – > 40 is ignored.Header –1 record15 records39 records <– Boundary condition40 records <– Boundary condition..Should be able to run both.Task II:****Working with Interfaces******Create and implement an interface to:Print student statistics.Print scores for a given student id.implement the Debug flag globallyUse an abstract class to implement all the methods declared in an interface.Create and implement an interface to:Print student statistics.Create and implement an interface to:Print student statistics.Print scores for a given student id.implement the Debug flag globallyUse an abstract class to implement all the methods declared in an interface.Print scores for a given student id.implement the Debug flag globallyUse an abstract class to implement all the methods declared in an interface.given data:1234 052 007 100 078 0342134 090 036 090 077 0303124 100 045 020 090 0704532 011 017 081 032 0775678 020 012 045 078 0346134 034 080 055 078 0457874 060 100 056 078 0788026 070 010 066 078 0569893 034 009 077 078 0201947 045 040 088 078 0552877 055 050 099 078 0803189 022 070 100 078 0774602 089 050 091 078 0605405 011 011 000 078 0106999 000 098 089 078 020

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] Student Grade Task 1 and 2
30 $