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
hram777 [196]
3 years ago
6

4.5 Code Practice

Computers and Technology
1 answer:
dmitriy555 [2]3 years ago
7 0

i = 0

while True:

   user_input = input("Please enter the next word: ")

   if user_input == "STOP":

       break

   i += 1

   print("#{}: You entered {}".format(i,user_input))

print("All done. {} words entered.".format(i))

First we set i equal to zero so that we can keep track of how many words we input.

We set while True so that its a continuous loop until a certain condition is met to break out of the loop.

user_input is set equal to whatever word the user enters.

our if statement tells us to break out of the while loop if the user inputs "STOP"

If the user does not enter STOP i is set equal to itself plus 1. This just means we add one to i for every new word entered.

Then we print whichever word is entered.

After the while loop, we print All done and the quantity of words entered.  

You might be interested in
1. The precious metals needed to make computer chips, graphic cards, and transistors are found in only a small population of cou
dexar [7]

Answer:

it means that they can charge companies to come mine it making them more wealthy they can also upscale the materials needed to make it as they are the only countries that sell it so they have no one to compete with

3 0
3 years ago
Most common level of education for a programmer or software developer
shusha [124]

c/c+ also java would be one

8 0
3 years ago
You want to design a small portable computer system with memory that can be updated, but that does not lose its contents when th
garri49 [273]

Answer:

CMOS

Explanation:

CMOS stands for complementary metal oxide semiconductor.  CMOS is in the design of several types of semiconductors. in most computers there are CMOS that are powered by the PC's batteries to save the memory state of  date, time, and system setup parameters when the PC looses power. In the question above, given the specified parameters for the new system, a CMOS chip will serve perfectly

7 0
3 years ago
Write a "while" loop equivalentto the following "for" loop: (2Points)
kap26 [50]

Answer:

int i,t = 0;

   i=0;  //initialize

   while(i<22){

       t = t + i;

           cout << t;

           i += 3;   //increment

   }

   cout << endl;

Explanation:

Loops are used to execute the part of the code again and again until the condition is not true.

In the programming, there are three loop

1. for loop

2. while loop

3. do-while loop

The syntax of for loop:

for(initialize; condition; increment/decrement){

   statement;

}

The syntax of while loop:

initialize;

while(condition){

   increment/decrement;

}

In the while, we change the location of initializing which comes before the start of while loop, then condition and inside the loop increment/decrement.  

6 0
4 years ago
An IT security threat is anything that might cause serious harm to a computer system.
Blababa [14]

Answer:

True

Explanation:

this is true because a threat can endanger the computer and its system

5 0
3 years ago
Other questions:
  • An Information Technology worker who follows the Programming and Software development pathway most likely enjoys
    15·2 answers
  • What are the two major categories of computer software? word-processing software and spreadsheet software applications software
    13·1 answer
  • (Microsoft excel) The data selected to create a table must include
    6·2 answers
  • Given the lists list1 and list2 that are of the same length, create a new list consisting of the first element of list1 followed
    12·2 answers
  • The advantage of an electronic ____ is that the content can be easily edited and updated to reflect changing financial condition
    10·1 answer
  • 4. You are planning to buy a new couch for your family room. Before you leave for the furniture store, you measure the available
    11·1 answer
  • Given an array a, write an expression that refers to the first element of the array .
    5·1 answer
  • When Google created its China-based search engine www..cn, they did not foresee eventually abandoning it because of censorship i
    12·1 answer
  • Describe the effects technology, particularly computers, has had on mechanical labor.
    8·1 answer
  • Name at least 3 different portable computer devices that can be purchased
    15·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!