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
Nana76 [90]
4 years ago
10

Write a program that reads a list of words. Then, the program outputs those words and their frequencies. Ex: If the input is: he

y hi Mark hi mark the output is: hey 1 hi 2 Mark 1 hi 2 mark 1
Computers and Technology
1 answer:
Tpy6a [65]4 years ago
4 0

Answer:

#Declare variable to get the input

#list from the user

input_list = input()

#split the list into words by space

list = input_list.split()

#Begin for-loop to iterate each word

#to get the word frequency

for word in list:

#get the frequency for each word

frequency=list.count(word)

#print word and frequency

print(word,frequency)

Explanation:

This program that we are told to write will be done by using python programming language/ High-level programming language.

The question wants us to write a program in which the output will be as below;

hey 1

hi 2

Mark 1

hi 2

mark 1

Just by imputing hey hi mark hi mark.

Just copy and run the code below.

#Declare variable to get the input

#list from the user

input_list = input()

#split the list into words by space

list = input_list.split()

#Begin for-loop to iterate each word

#to get the word frequency

for word in list:

#get the frequency for each word

frequency=list.count(word)

#print word and frequency

print(word,frequency)

You might be interested in
Which network type uses a coaxial cable to receive its signal?.
Tresset [83]
If you’re asking what I think your saying I know comcast does
6 0
2 years ago
Why do people yeet yeet and ree
DiKsa [7]

Answer:

Cause they are trying to be annoying

Explanation:

Something is wrong with them :)

8 0
3 years ago
Read 2 more answers
Ashley is the record keeper for a bookshop. She gathers and maintains an organized collection of information. What is Ashley usi
maks197457 [2]

The answer is Database.

Reason being is because because the definition of database matches the statement.

- Collection of information that is organized so that it can be easily accessed, managed and updated. 

3 0
3 years ago
Read 2 more answers
Which is the last line of defense in a physical security sense?
Deffense [45]

Answer: (A) People

Explanation:

 The physical security system is the basically used in the information system. It is used in the technical and the administrator element in the security system. This is the technology oriented system that is basically used to prevent from the hacking attacks in the system.

So, the people is the last statement of the defense in the physical security as the various security system is basically used by various people.

4 0
3 years ago
Your manager has asked you to recommend which of two new types of digital camera to buy for your company's publications departme
Neporo4naja [7]

Answer:

Website

Explanation:

In the digital world that we are in right now, the best place to conduct your research is online. By click of a mouse, I will be able to go through an unlimited list of websites online, search for the best digital cameras out there, do a purchase, and have the cameras delivered at the comfort of my chair. There are tremendous resources online that will help me choose what is the best for the company.

3 0
3 years ago
Other questions:
  • "a router interface has been assigned an ip address of 172.16.192.166 with a mask of 255.255.255.252. to which subnet does the i
    5·1 answer
  • Under which menu option of a word processing program does a star appear
    9·2 answers
  • You want to centrally back up the files users store in the Documents folder in their user profiles, but you don’t want users to
    7·1 answer
  • Question 1
    14·2 answers
  • What is wrong with the following C++ code? How would you fix it? int sum; for (int i=0; i<1000; ++i) sum += i; { printf("Sum
    5·1 answer
  • Define ethical (include a link to the source of definition). Describe the ethical dilemma (issue) in this scenario.
    12·1 answer
  • Philp has taken selfie wearing T-shirt that read "California 92." However, the text is mirrored in the selfie. He wants to uploa
    9·1 answer
  • How do you answer someone's question when they have asked?
    5·2 answers
  • What are the differences and similarities of computer virus and biological virus. Give 4 examples
    14·1 answer
  • According to the test for x-ray film freshness, the film is fresh and has been properly stored and handled when the processed fi
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!