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
finlep [7]
2 years ago
14

Write the function greeting that takes a string as input. That string will be formatted as Name Age Hobby, without any punctuati

on. greeting should split their response into list elements, then use index values to greet them by name and respond that you enjoy that hobby as well, with the format: ‘Hello, ! I also enjoy !' Make sure your output matches this format! For example, greeting('Jose 17 hockey') # => 'Hello, Jose! I also enjoy hockey!' greeting('Cindy 14 robotics') # => 'Hello, Cindy! I also enjoy robotics!'
Computers and Technology
1 answer:
Dmitriy789 [7]2 years ago
4 0

Answer:

The function in Python is as follows:

def greetings(details):

   details = details.split(' ')

   print('Hello, '+details[0]+'!, I also enjoy '+details[2])

Explanation:

This defines the function

def greetings(details):

This splits the input string by space

   details = details.split(' ')

This prints the required output

   print('Hello, '+details[0]+'!, I also enjoy '+details[2])

After splitting, the string at index 0 represents the name while the string at index 2 represents the hobby

You might be interested in
The ____________________ chip handles the functions of the keyboard controller.
RoseWind [281]
I think the ROM chip handles the functions of a keyboard controller.
7 0
3 years ago
Mikayla is researching copyright information for images found on a website. She needs to figure out the legal name of the compan
Pie

Answer:

C. Footer

Explanation:

A footer is typically found at the bottom of all web pages and it comprises of information such as disclaimers, copyright, legal which are displayed visibly for all visitors to see.

Generally, a website footer is the direct opposite of a website header in relation to positioning or location; a footer is always found at the bottom while a header is always found at the top of a web page.

Since Mikayla is researching copyright information for the images found on a website, she should access the website footer because it primarily provides information about the legal name of the company that owns the website and information about what country they're located in, as well as links to other relevant resources such as call to action, maps, contact forms, newsletter signup etc.

3 0
2 years ago
C++ Question: what is in the blanks?
Igoryamba

You didn't specify what the program should output, so there are many possibilities that result in a working program. It *looks* like this was intended:

int x = 24;

int y;

y = x-12;

cout<<y<<endl;

and it will display 12.

8 0
2 years ago
3. A hyperlink is important because it allows you to ___________. (1 point) click on the link to go directly to a website insert
ikadub [295]
A hyperlink is a link that can direct a person to another website when clicked. So the answer would click on the link to go directly to a website. To insert an image or sound you would use something else. And a hyperlink doesn't restrict a person to just the publisher information. I hope this helps!
3 0
2 years ago
Its inventiveness uncertainty and futuristic ideas deals with science and technology,what is it?
Sedaia [141]

Answer:

Capital FM

Explanation:

8 0
3 years ago
Other questions:
  • After you divide the viewfinder appropriately you locate the subject? PLZ ANSWER MY TEST DO BY TONIGHT
    13·1 answer
  • Question 4 / 5
    11·1 answer
  • Write the statements needed so that the variable secondWord is associated with the second word of the value of sentence . So, if
    13·1 answer
  • How to make changes to a file on the USB drive
    6·2 answers
  • A large population of ALOHA users manages to generate 50 requests/sec, including both originals and retransmissions. Time is slo
    5·1 answer
  • What is the best temperature to set your air conditioner on?
    12·1 answer
  • (Help please I don't know what to choose because it's both text and email but I can only pick one. HELP!!!!!!!!!!)
    6·2 answers
  • The declarations and statements that compose the method definition are called the __________.
    9·1 answer
  • (a) List 5 keys we can type with our left hand fingers
    9·1 answer
  • What is Data rate?<br> What is BAUD RATE?<br> What is bandwidth?
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!