Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Objectives

- Analyse, develop, and implement software solutions
- Choose and compare appropriate data structures in program design
- Apply classes, inheritance, polymorphism, and exception handling
- Test software implementations to ensure correctness and maintainability

Assignment 1 Specification

Introduction

For this assignment, you will write a Java windowed application to generate a maths speed test that students can use to sharpen their arithmetic calculation skills.

Overview of the application

The program generates a set of ten division questions. To do the test, the user sets the timer off, answers all ten questions and then submits the answers. Upon submission, the program automatically marks the test and displays performance statistics. Here a division question is defined as an integer division problem as Java programming integer division operation, where the result of division is an integer and the fractional part is ignored. For example, 5/2 gives the result 2 instead of 2.5.

The GUI
When the program is first started, the GUI should resemble the one given below.

The GUI components beginning from the top include:
- A top panel that contains a label for the title of the application and a label (invisible on this diagram) to display the timer.
- A middle panel that is divided into three columns. A text area is displayed on the right column of the middle panel. On the left are two sub- panels - one containing labels
for the ten division questions (each label will display a division question) and one containing ten text fields for the user answers.
- A bottom panel that contains a generate button, a start button, a submit button, a reset button and an exit button.

Some details of how the program functions

1. The user must generate the ten division questions before starting the test. Upon pressing the Generate button, ten division questions will be randomly generated and displayed on the panel. Each division problem will be an object of type Division class which contains three class data items -
the two operands of the division and the division result. The text fields are made uneditable so that the user does not start entering answers before pressing the Start button. For simplicity, we assume the two operands (i.e. dividend and divisor) ranges are in 1-50, and 1-10 respectively.

2. When the user clicks the Start button, the text fields are set to editable and the timer is started. The user then can enter answers into the text fields.

3. When the user has completed the test, he/she presses the Submit button and the test is automatically marked. The cells with the correct answers are coloured green and the ones with incorrect answers and invalid entries are coloured red. Score details are displayed on the text area. These include the time taken to complete the test, the number of correct answers, and the score achieved.

4. The formula for calculating the score is as follows:
Raw Score = 200 * (number of correct answers * 2.0) / (Time taken).
The Raw Score is cast to an integer. This is just an assumed simple calculation model. You may notice that the raw score depends on number of correct answer and the test time taken.

5. The Reset button resets the GUI to the state when the program is initially started, that is, as in the first diagram shown.

6. The Exit button terminates the application.

7. There are only three menu items, one under File menu, one under Edit menu and the other one under Help menu. When the user clicks the File → Save menu item, the program will save the data appeared on the text area (including the time taken in the test, number of correct answer, as well as the score achieved) to a text file named TestResult.txt. If the user clicks the Edit→ Reset menu item, the program will re-set the GUI as the Reset button does. If the Help→About menu item is clicked, a message box will pop up.

Division class

The Division class contains the data members of two operands (i.e. dividend and divisor) and the result of division, a constructor with two parameters of operands, as well as a get method to retrieve the quotient from the result of two operands division. As division operation is a typical example where division by zero should be avoided, appropriate exception handling and displaying message should be considered in the class definition. In the application class, a set of two random numbers are generated for Division class constructor as arguments.

Data Structures

- You need suitably named variables to store scores, clock and other variables.
- You will need using an object array that stores 10 Division objects. Each array element is a Division object. Thus 10 division questions are 10 elements of this array.
- You will need to use an inner class for the test timer. You can name the class name of the entire application as MathsChallenge or MathsInterface that contains GUI and main method.

Implementation platform

You will implement your program in Java using either the TextPad Editor (recommended) or NetBeans. NetBeans version 6.9 (or above) is available in University computing labs.

Attachment:- Assignment.rar

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92584474
  • Price:- $60

Priced at Now at $60, Verified Solution

Have any Question?


Related Questions in Computer Engineering

Question suppose your corporate commercial website server

Question : Suppose your corporate commercial Website server is located in a demilitarized zone (DMZ) so that potential and existing customers can access it. Explain the steps you would take to secure the Web server and t ...

Suppose mpc is 07 government spending increases by 10

Suppose MPC is 0.7. Government spending increases by $10 billion, and taxes decrease by $5 billion. How would the following items change, and by how much? Disposable income Private saving Public( Government) saving Equil ...

Research ways that information systems have been misused

Research ways that Information Systems have been misused. Using the Internet, find an example of an organization that has misused Information Systems. Post your response to the discussion board. Respond to the following ...

Answer the following questions whats the synchronous

Answer the following Questions : What's the synchronous distribution ? What are the guidelines for menu layout or list them?

Assignment 1 accessibilitybuilding a user interface that

Assignment 1: Accessibility Building a user interface that meets the needs of a diverse population can be incredibly difficult. Research the best practices for developing a universally usable interface, as well as some o ...

A chemistry student needsnbsp700 ml of dimethyl sulfoxide

A chemistry student needs 70.0 mL of dimethyl sulfoxide for an experiment. By consulting the  CRC Handbook of Chemistry and Physics , the student discovers that the density of dimethyl sulfoxide is 1.10 g.cm^-3. Calculat ...

Suppose youve designed a mips processor implementation in

Suppose you've designed a MIPS processor implementation in which the stages take the following lengths of time: IF=20ns, ID=10ns, EX=20ns, MEM=35ns, WB=10ns. What is the minimum clock period for which your processor func ...

Answer the following question -whats the difference between

Answer the following Question : -What's the difference between Anthropomorphic design and Non anthropomorphic design -What are the speech and auditory devices ? -What's the synchronous distribution ?

You have 2 tasks to createer-modeling in ms visio simple

You have 2 tasks to createER-Modeling in MS visio. Simple jab for the database expert that would take him 30 min to finish. My requirement not only for the expert to get the task done. I need to do it myself. Then he cor ...

1 write a critique review of the following paper2 your

1. Write a critique / review of the following paper. 2. Your critique should be as objective as possible: highlight what you consider to be its strongest and weakest aspects. Are themes discernible that would help one to ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As