Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

* * * * i need you to please write the full functional java code that avhieves all the requierments of this project ( the

****i need you to please write the full functional java code that avhieves all the requierments of this project (the full code not just steps on how to solve it).
***thank you in advance
--------------------------------------
In this course project, you are required to write a network application that implements a client/server quizzesenvironmentfor elementaryschool studentsusing TCP APIin Java. The environmentallows students(clients) to take math quizzesrelated to the four main operations +,-,*,\. Each quiz consists of a number of questions that are based onthesefour operations,with acertaindifficulty levelthat is determinedby the number of operations in the question and the number of digits that numbers consist of. The studentmust be able to provide the correct answer for each questionto earnthequestion point. The quiz total gradeis the summation of all earned questions points.Onthe server side:The server application must acceptclientsconnections and respond to them. The server must be able to handle more than one connectionat the same timebut for each connection it must not allow more than one quiz to be performed at the same time.When the client application is connected, the client mustbe asked continuouslytochoose either to: 1.Startanew quiz.2.Terminate.If the studentrequests to start a quiz, the program must start configuringsettings of the quiz by asking the student to specify the following:-The number of questions.-Whether atimeout must bespecified for questions, within which the student must provide the answer to be counted. If the student chooses to specify a timeout, he must be askedto enter this timeout (in seconds).-The difficulty of questions whichis specified by:oMaximum number of operationsthat questions consist of.Example-1:if the student chooses it tobe 1, all questions mustconsist ofexactlyone operation such as: 33+55,3*44,....Example-2:if thestudent chooses it to be 3, the questions could be any of the following: 44+5*2,32*3+3*5,55+11,......The maximum supported value for this option is 4.oMaximum number of digits that form numbers in thequestion.Example-1: if the student chooses it to be 1, then all numbers in the question must consist of exactlyone digit.Example-2: if the student choosesittobe 3, then numbers could consist of 1,2, or 3 digits.
When the quizstarts, foreach question, the server must select numbers and operations in the questionrandomly as specified in the quiz settings. The studentmust provide the correct answer within the specified timeout(if a timeout is specified). If so, the point of the question will be added to the total grade. For each question the student can sendonlyone answer. This process is repeated for all thequestions. Make sure to introduce a slight delay between each question and the next. The server application must compute the points by summing the points of the questions.The server must send the studentthequizresultwhich includesa report of all questions showingwhich questions were answered correctly and which were answered incorrectly along with the correct answer,then the quiz total grade.Ifthe client selects to terminate, the connection with the server must be terminated.Note that the server must preserve statistics info that includes:1.Total number of quizzes performed by all students.2.The numbersof quizzes performed that included one operation, two operations, threeoperations, and four operations.3.The numbersofquizzes for which students achieved:[0-25%)of thetotal grade.[25%-50%) of the total grade.[50%-75%) of the total grade.[75%-100%) of the total grade.100% of the total grade.This statistics infomust persist even if the server application is terminated. If thereis noactivity(receivedconnections) on the server sidefor 10 minutes, the server application must ask the admin whetherto:1.Continue waiting, in this case theserver application mustgo back to waiting for clientsconnections.2.Display statisticsand terminate,statistics info must be displayed to the admin and the server application must be terminated. Your final submission must include the following:1.Your code,fully documented.2.A report that includes the UML class diagram showing the design of your application data and methods.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Learning MySQL Get A Handle On Your Data

Authors: Seyed M M Tahaghoghi

1st Edition

0596529465, 9780596529468

Students also viewed these Databases questions

Question

explain why foreign exchange rates are so volatile

Answered: 1 week ago

Question

5.6 Describe alternatives to recruitment?

Answered: 1 week ago

Question

5.4 Identify external recruitment sources.

Answered: 1 week ago