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
blagie [28]
3 years ago
13

g Write a function called chain_words(str) which takes in one parameter which is a string that holds multiple words separated by

spaces. Your function should return a string with the words chained together with an - (hyphen). You can first split the words at spaces and then join the words with - (hyphen). You can achieve this by using split and join methods respectively.
Computers and Technology
1 answer:
Oduvanchick [21]3 years ago
7 0

Answer:

Explanation:

The following is written in Python. The function takes in a string as a parameter. It then sperates the string at every space. Then it rejoins the list of strings with hyphens. Finally, returning the newly created string with hyphens.

def chain_words(str):

   string_split = str.split(" ")

   seperator = '-'

   hyphen_string = seperator.join(string_split)

   return hyphen_string

You might be interested in
(01.05 LC)
andriy [413]
The answer is input! because the input is what the user enters, the output is what comes out from that, and the text and value aren’t related to the user
7 0
4 years ago
Read 2 more answers
Write a program named split_me.py that accepts a string in the format Age.FirstName and returns the value FirstName is Age years
zmey [24]

age,name = input('Enter a string: ').split('.')

print(name+' is '+age+' years old. Length of '+name+' is '+str(len(name)))

I wrote my code in python 3.8. I hope this helps.

5 0
3 years ago
Being able to express your thoughts in an email is a primary technology skill. true or false.
Zina [86]

almost everywhere else I've found this question the answer was false so i hope that helps.

5 0
3 years ago
Read 2 more answers
41. All the following software are examples of operating systems EXCEPT
Hunter-Best [27]

Answer:

vista

Explanation:

the other three I have used before

8 0
3 years ago
Analysts use _____ to show the objects that participate in a use case and the messages that pass between the objects over time f
ch4aika [34]

Answer:Sequence diagrams

Explanation: Sequence diagram is the diagram that displays about the connection of the objects in a sequential manner. The sequence depicted through the vertical lines in parallel form was about the object function and the horizontal line showed interaction between them for the exchange of the information.

Other options are incorrect because structural models have the infrastructure in particular format, communication diagrams depicts the exchange of information through communication and class diagram is the diagram that displays the system's class.Thus the correct option is sequence diagram.

5 0
3 years ago
Other questions:
  • What runs a network, steering information between computers and managing security and users?
    11·1 answer
  • In an is framework, ________ is the bridge between the computer side on the left and the human side on the right
    12·1 answer
  • During an interview, your non-verbal communication (body language, gestures, tone of voice, speed of talking,
    6·1 answer
  • Your program will demonstrate use of arrays, searching an array, using methods, passing parameters by reference, returning value
    13·1 answer
  • Which page in a web site do viewers usually see first?
    15·1 answer
  • Which iteration must have an expression that has a true or false value?
    11·2 answers
  • Using range(1,101), make two list, one containing all even numbers and other containing all odd numbers. How can I do this on Py
    15·1 answer
  • Extended essay on globalization not less than 200​
    6·1 answer
  • Refund please, this has not helped at all.
    6·2 answers
  • As a member of the help desk administration team, you've been assigned to update the driver for the network adapter that is inst
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!