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
Fed [463]
4 years ago
11

CHALLENGE ACTIVITY 2.15.1: Reading and outputting strings. Write a program that reads a person's first and last names, separated

by a space. Then the program outputs last name, comma, first name. End with newline. Example output if the input is: Maya Jones Jones, Maya.
Computers and Technology
1 answer:
dlinn [17]4 years ago
8 0

Answer:

Following are the program in Java language

import java.util.*; // import package

public class Main  // main function

{

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

{

    String l_name,f_name; // variable declaration

    Scanner sc6=new Scanner(System.in); // scanner class

   f_name= sc6.next(); // Read input

 l_name=sc6.next(); // Read input

 System.out.print(l_name); // display last name

  System.out.print(","); // display comma

   System.out.println(f_name); // display first name

}

}

Output:

Maya Jones

Jones, Maya

Explanation:

Following are the description of program

  • Declared a variable  'l_name","f_name" as the string type .
  • Create the instance of scanner class i.e "sc6".
  • Read the user input by using the instance "sc6" of the scanner class in the variable "l_name" and "f_name ".
  • Finally by system.print() method we will display the value according to the format in the given question .

You might be interested in
Write a program that accepts a positive integer N as command-line argument, and outputs True if N is the square of some integer,
Ann [662]

Answer:

In Python:

N = int(input("Positive integer: "))

if N > 0:

   flag = False

   for i in range(1,N+1):

       if i * i == N:

           flag = True

           break

   print(str(flag))

else:

   print("Positive integer only")

   

Explanation:

N = int(input("Positive integer: "))

If the number is positive

if N > 0:

This initializes a boolean variable to false

   flag = False

This iterates from 1 to the input integer

   for i in range(1,N+1):

This checks if th number is a square of some integer

       if i * i == N:

If yes, flag is set to true

           flag = True

The loop is exited

           break

This prints either true or false, depending on the result of the loop

   print(str(flag))

If otherwise, that the number is not positive

<em>else:</em>

<em>    print("Positive integer only")</em>

3 0
3 years ago
When text is used as a Hyperlink, it is usually underlined and appears as a different color.
Artist 52 [7]
True it usually shows up with a blue underline
7 0
3 years ago
2. Damaris is creating an object in Blender. He wants to change the illumination of the object that he is working on, but can’t
MariettaO [177]

The way that  Damaris can change the illumination of the object that he is working on in Blender is by:

  • First, one need to left-click on the lamp and then put  it in a place in your scene so that it can be able to illuminate the needed or required area. You can also do the above by  tweaking a lot of settings using the lamp options so that you can be able to get the lighting that you need . The most popular ones to tweak are those that have strength and color.

<h3>How do I change my light in Blender?</h3>

To view all options related to lights in Blender, enter the Object Data tab in the properties window while the lamp is still chosen.

You can alter your light kind and set energy and color settings at the top.

Therefore, The way that  Damaris can change the illumination of the object that he is working on in Blender is by:

  • First, one need to left-click on the lamp and then put  it in a place in your scene so that it can be able to illuminate the needed or required area. You can also do the above by  tweaking a lot of settings using the lamp options so that you can be able to get the lighting that you need . The most popular ones to tweak are those that have strength and color.

Learn more about Object from

brainly.com/question/2141363
#SPJ1

4 0
1 year ago
Create a float variable named circumference.
Likurg_2 [28]

Answer:

Float circumference; // Create a float variable

Explanation:

The float datatype is used for storing the decimal point values .The syntax  to declaring  any float variable is given below.

float variable-name;

float  circumference; // create a float variable

circumference=89.9007;; // store the value in circumference

Following are program in c++

#include <iostream> // header file

using namespace std; //namespace

int main() // main function

{

   float circumference; // creating variable float

   circumference=89.9007; // storing value

   cout<<circumference;  // display value circumference

   return 0;

}

Output:

89.9007

5 0
3 years ago
Which of these protects against the most common attacks on the internet via a database of signatures, but at the same time actua
BartSMP [9]

Answer:

Antivirus Software

Explanation:

The software that the question is describing is known as an Antivirus Software. Like mentioned, this is a computer program that is used with the main goal of preventing, detecting, and removing malicious files on the computer known as computer viruses. They also act as a shield to prevent these malicious files from entering the computer through the internet, but like any other software these Antivirus Softwares can be exploited by hackers to gain access into a system.

5 0
3 years ago
Other questions:
  • How can investors receive compounding returns
    13·1 answer
  • _____________ refers to know-what and know-why of technology.
    12·1 answer
  • The three tasks within data harmonization, namely: data consolidation, data cleansing, and data formatting use techniques called
    8·1 answer
  • Assume:
    14·1 answer
  • An expression which combines variables numbers and at least one operation
    8·1 answer
  • What are some hazards of being an astronomer??
    6·1 answer
  • Protocols at which layer of the OSI model have the primary function of moving datagrams through an internetwork connected by rou
    7·1 answer
  • Why is data processing done in computer?​
    14·1 answer
  • Charlie makes pizza at a restaurant. The customers always compliment how great the pizza tastes. But Charlie takes a long time t
    7·2 answers
  • Mainframe computers are multi-programming, high-performance computers, and multi-user, which means it can handle the workload of
    7·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!