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
Alika [10]
3 years ago
7

You want to know your grade in Computer Science, so write a program that continuously takes grades between 0 and 100 to standard

input until you input "stop", at which point it should print your average to standard output. Instructor Notes: Make sure to initialize counter and total to 0 Read the grades between 0 and 100: grade = input() Use while loop as long as the grades input is not equal to "stop" Make sure to total int(grades) Increment counter by one input the grade again Finally, print the average: total/counter
Engineering
1 answer:
Margarita [4]3 years ago
5 0

Answer:

The code is given below in python

# Code Block 1

count = 0  # count variable

total = 0  # total variable

enter = '' # input variable

while enter != 'stop':

   enter = input('Enter a grade:' )

   if enter != 'stop' and enter.isdigit():

       total += int(enter) # add to total value

       count = count + 1   # then to the count

print float(total) / count

# Code Block 2

numbers = []

while enter != 'stop':

   enter = input('Enter a grade:' )

   if enter != 'stop':

       numbers.append(int(enter))

print sum(numbers) / float(len(numbers))

You might be interested in
Name five or more items that were and may still be made by blacksmith
IgorLugansk [536]
Tools, weapons, hardware, armor
8 0
3 years ago
Explain what are rafters?
RSB [31]

Answer:

rafter is a structural component that is used as part of a roof construction. There are also different types of rafters

8 0
2 years ago
For unrestrained cube made from linear, isotropic, homogeneous material the temperature increase causes strain in_____ direction
LenKa [72]

Answer: The answer is four; four

Explanation: This is because of the mixture of material used and the number of directions it causes strain I directly proportional to the number of times it causes stress.

7 0
3 years ago
A 30 mm thick AISI 1020 steel plate is sandwiched between two 10 mm thick 2024-T3 aluminum plates and compressed with a bolt and
denis-greek [22]

Answer:

275 MPa

Explanation:

Regardless of what it is holding, the stiffness of a bolt depends on its own material properties and geometry.

The stiffness is:

k = E * \frac{A}{l}

I assume this one is made of steel, because regular bolts are steel.

The Young's modulus for steel is E = 210 GPa

The longitude is given. (But note that in a real application you have to consider the length up to the nut.)

The section is (using the nominal diameter of 10 mm)

A = \frac{\pi * d^2}{4} = \frac{\pi * 0.01^2}{4} = 7.85e-5 m^2

Then:

k  = 2.1e11 * \frac{7.85e-5}{0.06} = 275e6 Pa = 275 MPa

5 0
3 years ago
What is a table saw for
svet-max [94.6K]

Answer:

a table

Explanation:

because you can saw the table

5 0
2 years ago
Read 2 more answers
Other questions:
  • Question 5 (20 pts) The rated current of a three-phase transmission line is 300 A. The currents flowing by the line are measured
    6·1 answer
  • What’s is the proper fastener to use to join two wires.
    14·1 answer
  • With increases in magnification, which of the following occur? a. The field of view decreases. b. The ambient illumination decre
    9·1 answer
  • HW6P2 (20 points) The recorded daily temperature (°F) in New York City and in Denver, Colorado during the month of January 2014
    10·1 answer
  • In casting experiments performed using a certain alloy and type of sand mold, it took 170 sec for a cube-shaped casting to solid
    11·2 answers
  • Name the important trees of tropical monsoon forest​
    11·1 answer
  • Two substances, A and B, initially at different temperatures, come into contact and reach thermal equilibrium. The mass of subst
    6·1 answer
  • A flywheel made of Grade 30 cast iron (UTS = 217 MPa, UCS = 763 MPa, E = 100 GPa, density = 7100 Kg/m, Poisson's ratio = 0.26) h
    9·1 answer
  • An atom that gained an electron is called​
    10·2 answers
  • which type of irrigation fluid is typically used for endoscopic procedures using monopolar electrosurgery
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!