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
horsena [70]
2 years ago
8

It is good programming style to always use a for loop when the number of times to repeat the action is known. The following code

uses a while loop that mimics what a for loop should do. Rewrite it using a for loop that accomplishes exactly the same thing.
myprod = 1;
i = 1;
while i <= 4
num = input('Enter a number: ');
myprod = myprod ⁎ num;
i = i + 1;
end
Mathematics
1 answer:
Paraphin [41]2 years ago
7 0

myprod = 1

num = input("Enter a number: ")

for i in range(1, 5):

myprod *= num

You might be interested in
Please helpp meeee!!!!
nata0808 [166]

Answer: The answer is                                       because                                                 , hope this helps :)

Step-by-step explanation:

6 0
3 years ago
the area of a square whose sides have length x cm is increasing at the rate of 12cm²/s. how fast is the length of a side increas
katovenus [111]

Answer:

0.67 cm/s

Step-by-step explanation:

The area of a square is given by :

A=x^2 ....(1)

Where

x is the side of a square

\dfrac{dA}{dt}=12\ cm^2/s

Differentiating equation (1) wrt t.

\dfrac{dA}{dt}=2x\times \dfrac{dx}{dt}

When A = 81cm²​, the side of the square, x = 9 cm

Put all the values,

12=2\times 9\times \dfrac{dx}{dt}\\\\\dfrac{dx}{dt}=\dfrac{2}{3}\\\\\dfrac{dx}{dt}=0.67\ cm/s

So, the length of the side of a square is changing at the rate of 0.67 cm/s.

4 0
3 years ago
PLS HELP ILL MARK BRAINLYEST
Vitek1552 [10]

Answer:

Step-by-step explanation:

1 - a

2 - c

3 - b

5 0
3 years ago
What is 92 divided by 828
Natalija [7]
The answer is 9. if you wanna do it the long way buit a calculator is easier
3 0
3 years ago
Read 2 more answers
Are the graphs of the lines in the pair parallel? Explain. y = 4x – 4 24x – 4y = 96
zaharov [31]
No, since the slopes are different

for 1 line
y = 4x - 4

slope = 4

for 2 line
4y = 24x - 96
slope = 24/4 = 6
6 0
3 years ago
Read 2 more answers
Other questions:
  • How to solve a math equation step by step
    10·2 answers
  • Can someone please answer this ?
    6·1 answer
  • a group consisted of 2 girls for every boy. 24 girls joined the group. there are now 5 girls for every boy. how many boys are in
    7·2 answers
  • write an equation for this situation then Solve it. employee A gets paid $13 an hour .he got paid $591.50 this month. how many h
    9·1 answer
  • If a×b×c=0 and a and b are integers greater than 10 what must equal c
    10·2 answers
  • what is the surface area of the cylinder? Use 3.14 for pi and round your answer to the nearest hundredth
    7·1 answer
  • Each bucket holds 423 gallons of water. If it takes 8 buckets to fill a tank, how much water does the tank hold?
    10·1 answer
  • Could anybody explain simplifying fractions to me with an example?
    5·1 answer
  • A game decreased in price by 1/3. After the reduction it was priced at £12. What was the original price of the game?​
    5·2 answers
  • Sun-Li has $30 to spend at the carnival. Admission is $5, and each
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!