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
Len [333]
3 years ago
14

Python

Computers and Technology
1 answer:
Lemur [1.5K]3 years ago
3 0

Answer:

#Program starts here

#Prompt User for Input "FirstName and LastName "

FirstName = input("Enter Your FirstName: ")

LastName = input("Enter Your LastName: ")

#Define Function

def lastF(FirstName, LastName):

     FirstName = FirstName[0]+"."

     print(LastName+", "+FirstName);

lastF(FirstName, LastName) #Call Function

#End of Program

Explanation:

On line 3 and 4, the user is expected to enter his/her first name and last name respectively

On line 6, the function LastF with two arguments is defines

On line 7, the initial of FirstName is extracted

Line 8 prints the required output

Line 9 Calls the defined function.

You might be interested in
_____ is a function performed by control programs that manages computer resources, such as storage and memory.
Fudgin [204]
Resource allocation is a function performed by control programs that manages computer resources, such as storage and memory. It is necessary for any application to be run on the system because the computer is required to allocate certain resources for it to be able to run once the user opens any program.


5 0
3 years ago
With an example in each, describe the use of two basic functions which are known by the "string.h" header file.
olga nikolaevna [1]

Answer:

strcmp(char * A, char * B);

strcat(char * A, char * B)

Explanation:

One of these basic functions is the function strcmp(char * A, char * B).

This functions compares if two strings are equal; If they are, it returns 0. If not, it returns 1;

So, an example:

char A[13] = "Buffalo Bills";

char B[13] = "Buffalo Bills";

if (strcmp(A,B) == 0)

printf("The strings are the same\n);

else

printf("The strings are not the same");

In this case, they are the same.

----------------------

If for example:

char B[13] = "Buffalo Billz"

It would fall in the else, A and B would not be the same strings.

--------------------------

Other function is the strcat(char * A, char * B);

This function takes two strings as an input, and concatenate them to the first.

For example:

char A[15] = "Buffalo";

char B[5] = "Bills";

strcat(A, B);

printf("%s\n", A);

The output is:

Buffalo Bills

5 0
3 years ago
How do i cancel my brainly premium account?
Vikki [24]

Answer:

press cancel

Explanation:

5 0
3 years ago
Read 2 more answers
Can anybody answer this
shutvik [7]

Answer:

Its the last one, CSS and HTML are similar but like it says some prefer one over the other.

6 0
3 years ago
Read 2 more answers
Write a method named square that accepts an integer argument and returns the square of that argument.
BaLLatris [955]

Answer:

The method is as follows:

double square(int num){

return num*num;

}

Explanation:

Written in C++

This first line defines the method

double square(int num){

This line returns the square of num

return num*num;

}

<em>I've added the full program as an attachment where I include the main method</em>

Download cpp
7 0
3 years ago
Other questions:
  • Press the ____ key(s) to erase one character to the left of the insertion point.
    10·2 answers
  • wHAT ARE THE 5 LAYERS in the internet protocol stack andwhat are the principal responsibilities of eack of theselayers.?
    12·1 answer
  • Unit 3 Computer Programming Study Guide
    6·1 answer
  • Boolean expressions are named after ____
    9·1 answer
  • Camille prepared excellent PowerPoint slides for her speech about education reform, but the speech didn't go as well as she had
    15·1 answer
  • @anthonydboss23<br><br> it’s goldielove6 <br><br> .....this is not a question everyone ignore this
    11·2 answers
  • Java-Script Concept quiz:
    6·1 answer
  • FIGURE A-1—Use the information in this chart to answer Question 1.
    6·1 answer
  • What sort of negative outcomes are possible for this type of risk?
    14·2 answers
  • Que es el sistema persona producto?​
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!