Database System Concepts
Database System Concepts
7th Edition
ISBN: 9780078022159
Author: Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher: McGraw-Hill Education
Bartleby Related Questions Icon

Related questions

Question

Write a Java program to calculate a gamer's total XP score with a bonus per level. The program should:

 

1. Prompt and read the user’s input for the gamer's name, Level 1 XP (L1), Level 2 XP (L2), Level 3

XP (L3), and Engagement score (ES). User Scanner to read input.

2. Each XP score input should be in whole numbers between 10-100 and in increments

of 5.

The total XP score with bonuses should be calculated as follows:

L1+L1*0.20+L2+L2*0.30+L3+L3*0.50+ES+ES*0.60

3. Output the gamer's information and the total calculated XP score (including

bonuses).

4. Prompt the user as to whether they want to calculate total XP for another gamer and

repeat the input/output processing.

5. Allow the user to exit the program without inputting the gamer's data

 

Documentation

o Include header comments that include your name, date, and description of the

program.

o Include body comments.

o Consistent indentations

o Consistent white line spaces.

Here are a couple of sample runs:
RUN1:
Welcome to the Total XP calculation program!
Do you want to enter gamer's data? Yes/No => Yes
Enter gamer's name => Mark Smith
Enter gamer's Level XP scores separated by space: L1 L2 L3 ES => 90 90 80 75
Gamer Name: Mark Smith L1-90 L2=90 L3=80 ES=75
Final XP score with bonuses=465
Do you want to enter another gamer's data? Yes/No => Yes
Enter gamer's name => Sara Parker
Enter gamer's Level XP scores separated by space: L1 L2 L3 ES => 75 85 85 75
Gamer Name: Sara Parker L1-75 L2=85 L3=85 ES=75
Final XP score with bonuses=448
Do you want to enter another gamer's data? Yes/No => No
Thank you for using the Total XP calculation program!
RUN2:
Welcome to the Total XP calculation program!
Do you want to enter gamer's data? Yes/No => No
Thank you for using the Total XP calculation program!
expand button
Transcribed Image Text:Here are a couple of sample runs: RUN1: Welcome to the Total XP calculation program! Do you want to enter gamer's data? Yes/No => Yes Enter gamer's name => Mark Smith Enter gamer's Level XP scores separated by space: L1 L2 L3 ES => 90 90 80 75 Gamer Name: Mark Smith L1-90 L2=90 L3=80 ES=75 Final XP score with bonuses=465 Do you want to enter another gamer's data? Yes/No => Yes Enter gamer's name => Sara Parker Enter gamer's Level XP scores separated by space: L1 L2 L3 ES => 75 85 85 75 Gamer Name: Sara Parker L1-75 L2=85 L3=85 ES=75 Final XP score with bonuses=448 Do you want to enter another gamer's data? Yes/No => No Thank you for using the Total XP calculation program! RUN2: Welcome to the Total XP calculation program! Do you want to enter gamer's data? Yes/No => No Thank you for using the Total XP calculation program!
Expert Solution
Check Mark
Knowledge Booster
Background pattern image
Computer Science
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Text book image
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Text book image
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Text book image
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
Text book image
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education