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
3241004551 [841]
3 years ago
13

Check ALL of the correct answers.

Computers and Technology
1 answer:
Lelu [443]3 years ago
8 0

Answer:

2,3,4

Explanation:

Starts at two, goes to four. Thus it prints 2,3,4

You might be interested in
Which option is used in Access to locate and retrieve data that may be present in multiple database tables within the database?
rosijanka [135]

Answer:

subroutines

Explanation:

subroutines is used in access to locate and retrieve data

5 0
3 years ago
How does white balancing affect the images recorded by a camera?
garri49 [273]
It makes the images appear more brighter......?
5 0
4 years ago
Edhesive coding practice 3.4​
allsm [11]

I'm sorry i have to go to sleep.. Can we continue tm?

In the morning

8 0
4 years ago
Read 2 more answers
When an author produce an index for his or her book, the first step in this process is to decide which words should go into the
Igoryamba

Answer:

import string

dic = {}

book=open("book.txt","r")

# Iterate over each line in the book

for line in book.readlines():

   tex = line

   tex = tex.lower()

   tex=tex.translate(str.maketrans('', '', string.punctuation))

   new = tex.split()

   for word in new:

       if len(word) > 2:

           if word not in dic.keys():

               dic[word] = 1

           else:

               dic[word] = dic[word] + 1

for word in sorted(dic):

   print(word, dic[word], '\n')

                 

book.close()

Explanation:

The code above was written in python 3.

<em>import string </em>

Firstly, it is important to import all the modules that you will need. The string module was imported to allow us carry out special operations on strings.

<em>dic = {} </em>

<em>book=open("book.txt","r") </em>

<em> </em>

<em># Iterate over each line in the book</em>

<em>for line in book.readlines(): </em>

<em> </em>

<em>    tex = line </em>

<em>    tex = tex.lower() </em>

<em>    tex=tex.translate(str.maketrans('', '', string.punctuation)) </em>

<em>    new = tex.split() </em>

<em />

An empty dictionary is then created, a dictionary is needed to store both the word and the occurrences, with the word being the key and the occurrences being the value in a word : occurrence format.

Next, the file you want to read from is opened and then the code iterates over each line, punctuation and special characters are removed from the line and it is converted into a list of words that can be iterated over.

<em />

<em> </em><em>for word in new: </em>

<em>        if len(word) > 2: </em>

<em>            if word not in dic.keys(): </em>

<em>                dic[word] = 1 </em>

<em>            else: </em>

<em>                dic[word] = dic[word] + 1 </em>

<em />

For every word in the new list, if the length of the word is greater than 2 and the word is not already in the dictionary, add the word to the dictionary and give it a value 1.

If the word is already in the dictionary increase the value by 1.

<em>for word in sorted(dic): </em>

<em>    print(word, dic[word], '\n') </em>

<em>book.close()</em>

The dictionary is arranged alphabetically and with the keys(words) and printed out. Finally, the file is closed.

check attachment to see code in action.

7 0
3 years ago
How do you type multiple lines of code into IDLE? My Python environment does not look like the one projected in the lectures. I
natulia [17]
<span> The OSX IDLE provides the functionality of typing multiple lines of the code.  You can find the IDLE environment easily over the internet. </span><span />
5 0
4 years ago
Other questions:
  • 4. When determining the tone of their tweets, marketers should consider
    8·1 answer
  • Why should you stay out of the open space to the right of a semi-tractor-trailer?
    7·2 answers
  • Which software application should be used to communicate in writing about an upcoming event?
    12·2 answers
  • Which formal security-related process should take place at the beginning of the code creation project? Group of answer choices R
    13·1 answer
  • Why does my inbox keep getting notifications and then disappearing?
    15·2 answers
  • You are evaluating three branch prediction strategies: (1) predict always taken, (2) predict always not taken and (3) use the 2-
    14·1 answer
  • Order the steps to add a recommended chart in excel.
    5·2 answers
  • Seneca has just applied conditional formatting and realizes that she has made a mistake. Which action should she take to fix the
    12·2 answers
  • True or false we can used virus not use pirated software and programs ​
    10·1 answer
  • What is the grooming process as it relates to online predators
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!