Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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

image text in transcribed 

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

Step by Step Solution

3.42 Rating (158 Votes )

There are 3 Steps involved in it

Step: 1

Heres the program that meets the requirements java import javautilScanner public class VOStatements public static void mainString args Scanner keybd n... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Excellence in Business Communication

Authors: John V. Thill, Courtland L. Bovee

9th edition

136103766, 978-0136103769

More Books

Students also viewed these Operating System questions