Question
Project 2A - Quiz Application Data Model For this assignment, you don't have to take a quiz. Instead, you will build a data structure and
Project 2A - Quiz Application Data Model
For this assignment, you don't have to take a quiz.
Instead, you will build a data structure and application to support creating Quizzes similar to Kahoot (Links to an external site.) or Quizlet (Links to an external site.).
To get started, you will need to create a class structure using the following class diagram. The class diagram below is a simplified version of the design provided in a MySql tutorial I stumbled across (Links to an external site.) that you may want to reference for more detail about the class attributes defined in the diagram.
What to Do?
In your data structure, a quiz has certain attributes plus an aggregation of one-to-many questions with one-to-many answers. Aggregations in Java usually are a type of List, in our case List and List. You can use an ArrayList or another type of list of your choice.
Each Quiz has a host user (instructor). For simplicity's sake, we will not model the taking and tracking of quizzes for now. The user class, therefore, is used only for tracking hosts, but could later track quiz takers too in a full-blown quiz app.
Requirements
- Once you have created the data structure, you should populate it with your own data. You should create at least two quizzes with at least four questions, at least one true-false, and at least two multiple-choice questions.
- Your application should support a print operation that prints out two versions of your quiz a student version and an instructor version. The instructor version indicates the correct answer to the question.
- Additionally, the questions and answers should be shuffled before each print operation so you will need to use a randomizer function to shuffle the order of the questions before your print out.
- Your print-outs should be formatted similar to a real quiz.
- Your quiz should include show part of the host information at the top of the page and the quiz title and/or summary.
- You should test output should print out all quizzes that you have created (at least two).
Extra Credit: In order to reduce the tedium of grading for your professor, interesting or humorous quiz topics will get extra credit because if you're lucky, sometimes in life, your creativity is rewarded!
Submission Instructions:
Submit your completed java file(s) and screenshots of your test output. Robust testing is required and must be demonstrated.
1..* 1..* Quiz -id -title -summary -score -- total score -isPublished -- boolean --hostid - Userld of host -questions Question -id -quizld -type (t/f, select, etc) -level (easy, hard, medium) -score (value of question -answers Answer -id -quizld -questionld isActive -isCorect -answerText Use! -id -firstName -lastName -email -password - hashCode -isHost (boolean) -intro (host intro) 1..* 1..* Quiz -id -title -summary -score -- total score -isPublished -- boolean --hostid - Userld of host -questions Question -id -quizld -type (t/f, select, etc) -level (easy, hard, medium) -score (value of question -answers Answer -id -quizld -questionld isActive -isCorect -answerText Use! -id -firstName -lastName -email -password - hashCode -isHost (boolean) -intro (host intro)Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started