1/0 Statements and Formatting-featuring the Scanner Class, printf & String.format Create a program which reads any...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
1/0 Statements and Formatting-featuring the Scanner Class, printf & String.format Create a program which reads any company's name, followed by their top two employees and their employee number and salary. Make your program output is EXACTLY as shown in the sample session below. Be sure to centre the title of the company name and complete the data chart as shown. Assume the maxPageWidth is 50 characters. Helpful It is the tab character In is the new line character String.format("%, 12.0f", 48500000); String.format("%,09d", 400); Sample Session Remember when reading int or double from the keyboard, via the Scanner class, include the extra line, as shown below: Int number keybd.nextInt(); keybd.nextLine(); Enter the Company Name: Microsoft Corporation Enter employee name #1: Satya Nadella = Enter employee number #1: 400 Enter employee number #1 salary: 48500000 Enter employee name # 2: Scott Guthrie Enter employee number #2: 230 Enter employee number # 2 salary: 114,600 Number Name 00000488 SATYA NADELLA 00000230 SCOTT GUTHRIE 12345678901234567890123456789012345678901234567898 Microsoft Corporation Salary 48,500,000 114,600 12345678901234567890123456789012345678901234567890 1/0 Statements and Formatting-featuring the Scanner Class, printf & String.format Create a program which reads any company's name, followed by their top two employees and their employee number and salary. Make your program output is EXACTLY as shown in the sample session below. Be sure to centre the title of the company name and complete the data chart as shown. Assume the maxPageWidth is 50 characters. Helpful It is the tab character In is the new line character String.format("%, 12.0f", 48500000); String.format("%,09d", 400); Sample Session Remember when reading int or double from the keyboard, via the Scanner class, include the extra line, as shown below: Int number keybd.nextInt(); keybd.nextLine(); Enter the Company Name: Microsoft Corporation Enter employee name #1: Satya Nadella = Enter employee number #1: 400 Enter employee number #1 salary: 48500000 Enter employee name # 2: Scott Guthrie Enter employee number #2: 230 Enter employee number # 2 salary: 114,600 Number Name 00000488 SATYA NADELLA 00000230 SCOTT GUTHRIE 12345678901234567890123456789012345678901234567898 Microsoft Corporation Salary 48,500,000 114,600 12345678901234567890123456789012345678901234567890
Expert Answer:
Answer rating: 100% (QA)
Heres the program that meets the requirements java import javautilScanner public class VOStatements public static void mainString args Scanner keybd n... View the full answer
Related Book For
Excellence in Business Communication
ISBN: 978-0136103769
9th edition
Authors: John V. Thill, Courtland L. Bovee
Posted Date:
Students also viewed these operating system questions
-
Objectives This case study's main objective is to allow students to learn more about operating systems and their most common issues. Select their preferred area in the field of operating systems and...
-
Protecting Critical Infrastructure and the Homeland The Department of Defense (DoD) Cyber Strategy 2018 discusses the protection of critical infrastructure and the homeland. What does that mean to...
-
importance of workalike balance for women as a leader in healthcare. 1. The purpose of the research; 2. Research question/s; 3. Findings and relevant data; 4. Any recommendations and; 5. The...
-
If a charge on the body is InC, then how many electrons are present on the body? (a) 1.6 10-19 (c) 6.25 10 (b) 6.25 x 101 (d) 6.25 x 108
-
Refer to the 10-K reports of Under Armour, Inc., and Columbia Sportswear that are available for download from the companion website at CengageBrain.com. Required: 1. What amounts do Under Armour and...
-
Virginia Tech operates its own power generating plant. The electricity generated by this plant supplies power to the university and to local businesses and residences in the Blacksburg area. The...
-
Identify objectives and solution features for the following products: a. An ATM. b. An accounting information system. c. A carwash. d. A car.
-
The comparative balance sheet for Mosaic Travel Services, Inc., for December 31, 2014 and 2013, is as follows: The following information is taken from the records of Mosaic Travel Services, Inc.: a....
-
Image transcription text YAW Dynamics: Char. Velocity = 32 mph or 14 m/s Estimated Front mu = 0.55 Max Speed 130R = 59 mph Roll Dynamics: SSF = 69in / 56.2in = 1.22 Rear Ride Rate = 320lbs/2/ 0.5in =...
-
Braganza manufactures and sells 20 000 copiers each year. The variable and fixed costs of reworking and repairing copiers are as follows: Braganza's engineers are currently working to solve the...
-
Provide the names of variables in a data frame with at least three variables in which one of them is an identification variable and the other two are not. In other words, create your own tidy data...
-
Tristan is single, aged 47, and an active plan participant. His adjusted gross income, or AGI, for 2024 is $82,000. Based on the 2024 phase out range of $77,000 - $87,000 for single filers who are...
-
Consider the following information for Gelato Supremo for 5.000 units: Gelato Supremo Revenue and Spending For the Month Ended June 30th Costs Cost Per liter Variable Element Fixed Elem ent 5000...
-
Both Thu and Juan own one-half of the stock of Wren, Inc., a C corporation. Each shareholder holds a stock basis of $175,000. Wren holds accumulated E & P of $300,000. Wren's taxable income for the...
-
What is the role of resource breakdown structures with managing project costs for a HR Manual?
-
Lance Glasses is an eyewear manufacturer that featured on Kickstarter. The company reported $180,000,000 in revenues for 2021 and $45,000,000 in Cost of Goods Sold (COGS). In the same year, the...
-
1. Discuss the relationship between values and behavior of authentic transformational leadership. Provide and explain an example of when transformational leadership is inauthentic. 2. Review Niccol`o...
-
A woman at a point A on the shore of a circular lake with radius 2 mi wants to arrive at the point C diametrically opposite on the other side of the lake in the shortest possible A time. She can walk...
-
You've completed your slide show on the agile organization, and you've been looking forward to giving the presentation for the first time. The presentation is going along nicely until you notice one...
-
How can you apply the "you" attitude when you don't know your audience personally?
-
It's hard to go through life without becoming annoyed at the way some things work. You have undoubtedly been dissatisfied with a product you've bought, a service you've received, or an action of some...
-
If you stood atop a super-tall ladder three times as far from Earths center as at Earths surface, how would your weight compare with it present value?
-
How was Pioneer 10 able to escape the solar system with an initial speed less than escape speed?
-
With no gravity, a horizontally moving projectile follows a straight-line path. With gravity, how far below the straightline path does it fall compared with the distance of free fall?
Study smarter with the SolutionInn App