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
IceJOKER [234]
3 years ago
6

Write a function named initialMatch that takes a string parameter, text, that contains only lowercase letters and whitespace. Th

e function initialMatch should return a dictionary in which each word in text is a key. The value of each key should be a list of all words in text that satisfy the following three conditions: 1. all words in the list should have the same initial letter as the key 2. no word in the list should appear more than once 3. the key shouldn’t be in the list For example, the following would be correct input and output:
Computers and Technology
1 answer:
Furkat [3]3 years ago
6 0

Answer:

Implementing on Python for the question, the following is the code.

Explanation:

def intialMatch(l):

   word_dict={}

   for word in l.split():

       if word_dict.get(word)==None:

           word_dict[word]=[]

       for key in word_dict.keys():

           if key[0]==word[0] and (word is not key) :

               values = word_dict.get(key)

               if word not in values:

                   values.append(word)

       for key,values in word_dict.items():

           for value in values:

               if value==key:values.remove(value)

   return word_dict

t='do what you can with what you have'

print(intialMatch(t))

You might be interested in
Which action could be used to determine if a host is compromised and flooding traffic onto the network?
timofeeve [1]

<span>Disconnect the host from the network. 
</span><u>if that doesnt work then try these options</u> 
Check the host hard drive for errors and file system issues.
<span>Examine the Device Manager on the host for device conflicts
</span>Unseat and then reconnect the hard drive connectors on the host.

4 0
3 years ago
____________________________ and _________________________ are 2 negative impacts of the internet on businesses.
Bogdan [553]

Answer:

i no you its me remember and the answer is b.

Explanation:

7 0
3 years ago
Topic: Video Games.
Butoxors [25]

Answer:

Fire Emblem

Explanation:

4 0
3 years ago
WHO WANTS TO PLAY AMONG US
Elza [17]

Answer:

Explanation:

ME

8 0
3 years ago
Read 2 more answers
Generally speaking, the _______ the risk, the _______ the potential return or loss
givi [52]
<span>The correct answer is higher for both blank spaces.

We all know the famous saying: "No risk, no reward". What is true is the higher your risk you also have a higher degree of reaping a higher rewards. But the opposite is also true, the more you risk the more you stand to lose. In stockbroker business this is best exemplified, as you can se brokers trying to predict the stock market in order to make greater profits. Gambling is also the good example of this. </span>
6 0
3 years ago
Read 2 more answers
Other questions:
  • Nancy would like to configure an automatic response for all emails received while she is out of the office tomorrow, during busi
    13·2 answers
  • What effect did personal computers and internet have on how people acces information
    6·2 answers
  • The ________ is an area where you can position fields to use for filtering the PivotTable and thereby enabling you to display a
    11·1 answer
  • Arrays are described as immutable because they are two dimensional. are arranged sequentially. can be reordered. cannot be chang
    11·1 answer
  • Saas provides services to an organization that requires the standard business process infrastructure such a CRM
    7·1 answer
  • What kind of company would hire an Information Support and Service employee?
    7·1 answer
  • Select the correct answer.
    12·2 answers
  • Does the Main Content (MC) of a web page include searchboxes?
    8·2 answers
  • Select the correct answer.
    10·1 answer
  • List any two programs that are required to play multimedia products
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!