1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Katena32 [7]
3 years ago
11

Write a program that does the following:

Computers and Technology
1 answer:
Nataly_w [17]3 years ago
8 0

Answer:

Following is the program in Java language:

import java.util.*;//import package

public class Main // main class

{

public static void main(String[] args) // main method

{

    String  firstname,lastname; // Declare the two String variables

    Scanner ob=new Scanner(System.in); // create a object of scanner //class

    System.out.println("Enter the first name:");  // Prompt the user for // enter the first name

   firstname=ob.nextLine();// Read in the first name by user

    System.out.println("Enter the last name:"); // Prompt the user for last //name

   lastname=ob.nextLine();// Read in the last name by user

   System.out.println("Hello " + firstname +' ' +lastname); // print the //firstname,lastname

}

}

Output:

Enter the first name:

San

Enter the last name:

ert

Hello San ert

Explanation:

Following are the description of program

  • Declared two variable of string type i.e "firstname"  and "lastname".
  • Create a instance or object  of scanner class .i.e "ob".
  • Prompt the user to enter the first name in the  "firstname" variable
  • Read in the first name by the user by using the method nextLine() in the first name variable
  • Prompt the user to enter the  last name.
  • Read in the last name by the user by using the method nextLine() in the lastname variable.
  • Finally, print the first name and last name.

You might be interested in
What is the output from main (below) after the following function is called. void calculateCost(int count, double& subTotal,
GalinKa [24]

Answer:

     

Explanation:

7 0
3 years ago
Which TranscribeMe tag should you use if you are unable to make out a word or phrase due to a difficult accent, poor audio, or a
Lady bird [3.3K]

Answer:

[inaudible]

Explanation:

TranscribeMe is an online transcription company. It employs people all over the world to render transcription services to clients. They have a style guideline which must be strictly adhered to by the transcribers. The guidelines specifically states the "do's " and "dont's" during transcription. Now, when transcribing a word or phrase that cannot be heard or understood due to poor audio or difficult answer, the transcriber uses the tag [inaudible].

5 0
2 years ago
Course Aggregation Many times, departments are only interested with how students have done in courses relative to a specific maj
nadezda [96]

Answer:

def course_grader(student_to_grades, course_prefix):

   student_grades = dict()

   for key, value in student_to_grades.items():

       grade_score = 0

       for course,grade in value.items():  

           if course_prefix == course:  

               grade_score += grade

                student_grades[key] = grade_score / len(value.keys())

   return student_grades

Explanation:

The course_grader function is a python program that accepts two arguments, the student dictionary and the course prefix. The function returns a dictionary of the student id as the key and the average grade of the student as the value.

8 0
2 years ago
Describe the difference between fuses and circuit breakers. where might each type of device find its best use? g
ycow [4]
Here i found this link that might help!
https://study.com/academy/lesson/the-differences-between-fuses-circuit-breakers.html

Have a nice day!
3 0
3 years ago
Which line of code will print I like to code on the screen? print("I like to code") print(I like to code) print("I LIKE TO CODE"
Bad White [126]

Answer:

print("I like to code")

Explanation:

In the Programming Languages, print() function is used to print any string, display any output or both at the same time as well as we can print it one by one. We can also print addition, subtraction, multiplication and other problems directly without saving it in other objects or variables.

In the above statement, the correct method of printing any string is to write that string inside the parameter with a double-quote.

The second option is incorrect because in it double-quote is not used.

The third option is incorrect because the following sequence is not correct.

4 0
3 years ago
Read 2 more answers
Other questions:
  • Name size of machine screw that is used to secure switches and receptacles to device boxes
    13·1 answer
  • Text, numbers,graphics, sounds entered into a computer's memory during input operations are referred to as
    11·1 answer
  • What were precomputed tables and why were they necessary?​
    12·2 answers
  • 24 bit or 16 million colors is often called?
    7·1 answer
  • To help determine which technology to use, Raul creates a table to help him compare the pros and cons of his choices. What part
    15·1 answer
  • While designing your network's VLAN topology, your team has decided to use a centrally managed DHCP server rather than creating
    8·1 answer
  • Match each word to its correct meaning.
    5·1 answer
  • How can you solve real world mathematical problems using two linear equations in two variables​
    11·1 answer
  • What is the other name of the horizontal column graph
    9·1 answer
  • Justify any FOUR significant factors to remember when installing your motherboard
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!