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
arlik [135]
3 years ago
13

The function below takes two string parameters: sentence is a string containing a series of words separated by whitespace and le

tter is a string containing a single lower case letter. Complete the function to return a string containing one of the words in sentence that contains letter (in either upper case or lower case). Your code should return the word with its capitalization in the original sentence. If there are multiple words in sentence that contain letter, you can return any of them.
Computers and Technology
1 answer:
postnew [5]3 years ago
4 0

Answer:

Python 3 code used below

Explanation:

def word_extraction(sentence,letter)

  //splitting the sentence into individual words

  words=sentence.split()

  for word in words:

//This will take care of the word in lower

      if letter in word.lower():

         return word

  return ""

# Testing the function here. ignore/remove the code below if not required

print(extract_word_with_given_letter('hello HOW are you?', 'w'))

print(extract_word_with_given_letter('hello how are you?', 'w'))

You might be interested in
The two rules within Title II of hippa that have the greatest relevance and impact on the business associates are
Ne4ueva [31]
The two rules within Title II of HIPPA (Health Insurance Portability and Accountability Act) that has great relevance and impact on the business associates are: 

1. Privacy Rule - stating of child welfare agencies
2. Security Rule - complying of HIPPA requirements
5 0
3 years ago
Read 2 more answers
2.3.<br> Why is a foundation of particular importance when building and designing<br> structures?
bearhunter [10]

Answer:

A foundation plays three major roles in the construction of a structure. A good and strong foundation keeps the building standing while the forces of nature wreak havoc. Well-built foundations keep the occupants of the building safe during calamities such as earthquake, floods, strong winds etc.

6 0
2 years ago
What is the role of UPS in Computer security?<br>4 marks answer​
Studentka2010 [4]

Answer:

UPS is used to protect hardware like computers, data centers, telecommunication equipment or other electrical equipment where an unexpected power disruption could cause injuries, serious business disruption or data loss

4 0
3 years ago
To import data to a table, tap or click the ____ tab on the ribbon.
Ivenika [448]
To be able to import data on a table in your power point presentation, you have to tap or click the "Text File" tab on the ribbon part of the menus.
BY this, you will be able to import the data you need on the table you created. 
6 0
3 years ago
how do i set it up? can u guys like give examples its for computer science its suppose to be a program
trasher [3.6K]

public class Lab02_Favorite{

    public static void main(String []args){

       System.out.println("I miss going bowling with my friends");

    }

}

7 0
3 years ago
Other questions:
  • Which type of statement is used to communicate one’s feelings in a nonconfrontational manner?
    14·1 answer
  • Why are streak plates used to test minerals?
    8·1 answer
  • This diagram shows a number of computing devices connected to the Internet with each line representing a direct connection.
    11·1 answer
  • Rosa is a high school freshman with no savings. She wants to buy a new smartphone in a few months for $300. Which account type b
    9·2 answers
  • Which type of image format is constructed using proportional formulas rather than pixels? This task contains the radio buttons a
    12·2 answers
  • Suppose an IP packet is fragmented into 10 fragments, each with a 1% (independent) probability of loss. To a reasonable approxim
    15·1 answer
  • Four reasons why computers are powerful
    14·1 answer
  • Which of the following statements best describes cell protection when it is first activated?
    7·1 answer
  • CSCU EXAM TEST FINAL1-A software or hardware that checks information coming from the Internet and depending on the applied confi
    6·1 answer
  • Why do you need to put your phone on airplane mode.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!