Ask Java Expert


Home >> Java

1. Create a Java Application Project named PRJ1[Last Name][First Initial]. As an example, if your name was Xavier Smith, then the project would be named PRJ1SmithX.

2. Review the requirements for the program (3 a. - 3 h.) then generate a test plan in a document named PRJ1SmithXTestPlan using the Test Plan Example document listed in Week 1 Activities as a guide. An example is presented in this document for your consideration.

3. Once you are in the IDE with the tabbed PRJ1SmithX.java in the Source window, begin developing the following program:

a. Declare all appropriate identifiers for the program.

b. Have a set of prompts that request a user's (1) first name, (2) middle initial, (3) last name, (4) age in years, and (5) three lucky numbers in a set of Input Dialog Boxes (JOptionPane.showInputDialog()).

c. Display a welcome message in a Message Dialog Box (JOptionPane.showMessageDialog()) that includes the full name, e.g., "Welcome John Q Smith.".

d. Display the message from the Output column from the table below in a Message Dialog Box based on the age entered:

If the age input is Output

Less than 12 years* You are just a kid!

12 years You are almost there.

13 years but less than 20 years Welcome teenager.

20 years but less than 21 years Welcome almost adult.

21 years but less than 65 years Welcome adult.

65 years or older Welcome Senior Citizen.

*It is assumed that "less" means entering at least a 1 in the first test instance. There will not be any tests for a value of 0 or any negative numbers for this assignment, though it would be expected to check for these values in a real world program.

e. For determining the appropriate output for the Message Dialog Box in d., use a single test per condition contained in a cascading conditional structure avoiding all unnecessary, redundant coding.

f. Display appropriate text in a Message Dialog Box for the average of the three lucky numbers, e.g., "The average of your three lucky numbers is: 20."

g. When the user ends the program include a final line of text after a blank line: "Thanks for sharing your information, [first name from entry]."

h. Add the appropriate documentation to the program as suggested in the Documentation for Programs document listed in Week 1 Activities as a guide.

[As an alternative for the three Message Dialog Boxes, you can attempt to place all three output messages (name, age message, and lucky number average - think \n) in the same Message Dialog Box. This is not a requirement.]

4. When the assignment works correctly for all parts, capture images of the results - screen shots - for each of the test plan sets of data - the program will have to run for each of the sets - and paste each of them after the test plan prepared in Item 2. above into PRJ1SmithXTestPlan. The document contains the following: your test plan matrix followed by each of the screen shot sets of output. Each of the screen shot sets is tagged as Test Output 1, etc. or whatever term you prefer to use.

5. Once you complete the Project 1 program attach the PRJ1SmithX.java and PRJ1SmithXTestPlan files to the appropriate location in LEO.

Java, Programming

  • Category:- Java
  • Reference No.:- M92020956
  • Price:- $40

Priced at Now at $40, Verified Solution

Have any Question?


Related Questions in Java

Chatbotscreate a small networked chat application that is

Chatbots Create a small, networked chat application that is populated by bots. Introduction On an old server park, filled with applications from the early days of the internet, a few servers still run one of the earliest ...

Assignment taskwrite a java console application that allows

Assignment task Write a java console application that allows the user to read, validate, store, display, sort and search data such as flight departure city (String), flight number (integer), flight distance (integer), fl ...

Assignment game prototypeoverviewfor this assessment task

Assignment: Game Prototype Overview For this assessment task you are expected to construct a prototype level/area as a "proof of concept" for the game that you have designed in Assignment 1. The prototype should function ...

Assignment taskwrite a java console application that allows

Assignment task Write a java console application that allows the user to read, validate, store, display, sort and search data such as flight departure city (String), flight number (integer), flight distance (integer), fl ...

In relation to javaa what is constructor the purpose of

(In relation to Java) A. What is constructor? the purpose of default constructor? B. How do you get a copy of the object but not the reference of the object? C. What are static variables and instance variables? D. Compar ...

Project descriptionwrite a java program to traverse a

Project Description: Write a java program to traverse a directory structure (DirWalker.java) of csv files that contain csv files with customer info. A simple sample in provided in with the sample code but you MUST will r ...

Fundamentals of operating systems and java

Fundamentals of Operating Systems and Java Programming Purpose of the assessment (with ULO Mapping) This assignment assesses the following Unit Learning Outcomes; students should be able to demonstrate their achievements ...

Assessment -java program using array of Assessment -JAVA Program using array of objects

Assessment -JAVA Program using array of objects Objectives This assessment item relates to the course learning outcomes as stated in the Unit Profile. Details For this assignment, you are required to develop a Windowed G ...

Applied software engineering assignment 1 -learning

Applied Software Engineering Assignment 1 - Learning outcomes - 1. Understand the notion of software engineering and why it is important. 2. Analyse the risk factors associated with phases of the software development lif ...

Retail price calculatorwrite a java program that asks the

Retail Price Calculator Write a JAVA program that asks the user to enter an item's wholesale cost and its markup percentage. It should then display the item's retail price. For example: (If an item's wholesale cost is 5. ...

  • 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