subject

1. Add an import statement above the class declaration to make the Scanner class available to your program. 2. In the main method, create a Scanner object and connect it to the System. in object.
3. Prompt the user to enter his/her first name.
4. Read the name from the keyboard using the nextLine method, and store it into a variable called firstName (you will need to declare any variables you use).
5. Prompt the user to enter his/her last name.
6. Read the name from the keyboard and store it in a variable called lastName.
7. Concatenate the firstName and lastName with a space between them and store the result in a variable called fullName.
8. Print out the fullName.
9. Compile, debug, and run, using your name as test data.
10. Since we are adding on to the same program, each time we run the program we will get the output from the previous tasks before the output of the current task.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 20:30
Write a program that reads the file, then displays the average number of steps taken for each month. (the data is from a year that was not a leap year, so february has 28 days.) your program needs to use at least 3 functions not counting main and display the information in a neat well formatted fashion.
Answers: 3
question
Computers and Technology, 22.06.2019 02:30
Your boss wants you to configure his laptop so that he can access the company network when he is on the road. you suggest a vpn connection to him. he is very concerned about security and asks you how secure vpn is. what do you tell him?
Answers: 1
question
Computers and Technology, 22.06.2019 10:00
Businesses allocate resources for their best and most productive uses. the more a resource, the more costly it will be. a manufacturer that requires scarce and costly resources is likely to charge for its products.
Answers: 2
question
Computers and Technology, 22.06.2019 10:30
Think about a recent customer service experience - either positive or negative. write a brief summary of that experience. now think about those four characteristics we look for in customer service representatives. how did the representative in your example stack up? write down your answer and give specific examples.
Answers: 1
You know the right answer?
1. Add an import statement above the class declaration to make the Scanner class available to your p...
Questions
question
Advanced Placement (AP), 03.02.2020 10:51
question
Mathematics, 03.02.2020 10:51
question
Biology, 03.02.2020 10:51
Questions on the website: 13722362