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
8

Assume there is a variable, h already associated with a positive integer value. write the code necessary to compute the sum of t

he first h perfect squares, starting with 1. (a perfect square is an integer like 9, 16, 25, 36 that is equal to the square of another integer (in this case 3*3, 4*4, 5*5, 6*6 respectively).) associate the sum you compute with the variable q. for example, if h is 4, you would assign 30 to q because the first 4 perfect squares (starting with 1) are: 1, 4, 9, 16 and 30==1+4+9+16. submit
Mathematics
1 answer:
ludmilkaskok [199]3 years ago
8 0
Let q be the variable to be computed associated with h. the code is given below as  
q=0 / initial value assigned is 0 
for i in range(1,h+1): / for loop is formatted with range 1 t0 h+1 
q+=i**2 / sum q is computed as square of i
You might be interested in
Noah brought 1 fishing pole, 2 corks, and 1 worms. What is the total cost? Each fish cost $2. Corks is 2 fish, poles is 5 fish,
slava [35]
The total cost is 21.50.

Hope this helps!!
3 0
3 years ago
Read 2 more answers
"A cash drawer contains 29 bills, all twenties and fifties. If the total value of the bills is $820, how many twenties and how m
maks197457 [2]

Answer:

There are 21 twenties and 8 fifties in the drawer.

Step-by-step explanation:

This question can be solved by a system of equations.

I am going to say that:

x is the number of twenties

y is the number of fifties.

A cash drawer contains 29 bills.

This means that x + y = 29.

The total value of the bills is $820.

This means that 20x + 50y = 820.

So

x + y = 29

20x + 50y = 820

From the first equation, x = 29 - y. So:

20x + 50y = 820

20(29 - y) + 50y = 820

580 - 20y + 50y = 820

30y = 240

y = 8

And

x = 29 - y = 29 - 8 = 21

There are 21 twenties and 8 fifties.

3 0
4 years ago
Read 2 more answers
Cathy uses 9.1 pints of blue paint and white paint to paint her bedroom walls. 1 4 of this amount is blue paint, and the rest is
ratelena [41]

Answer:

She used 6.825 pints of withe paint to paint her bedroom walls

Step-by-step explanation:

We know Cathy used 9.1 pints of paint and 1/4 is blue.

first we have to calculate the white paint, we are going to calculate it by subtracting 1/4 of the total paint

1 - 1/4 = 4/4 - 1/4 = 3/4

Now that we know that 3/4 of the total paint is white, we have to multiply it by the amount of paint so we get how many pints of paint are white

3/4 * 9.1 = 6.825

She used 6.825 pints of withe paint to paint her bedroom walls

7 0
3 years ago
I'm re-uploading it. Please help i will give brainliest to first answer!
alisha [4.7K]

Answer:

here are the graphs i drew

Step-by-step explanation:

hope this helps!! :)

Download pdf
7 0
3 years ago
What is the midpoint of this point (-4,2) and (8,0)? ​
marissa [1.9K]

Answer:

Mid - point = ( 2 , 1 )

Step-by-step explanation:

Let A = ( - 4 , 2 ) and B = ( 8 , 0 )

Let P = ( x , y ) be the mid-point of AB

Then,

     P = (\frac{x_A + x_B}{2} , \frac{y_A + y_B}{2} ) \\\\P =(\frac{-4+8}{2} , \frac{2+0}{2}) \\\\P = ( \frac{4}{2} , \frac{2}{2} )\\\\P = ( 2 , 1)

6 0
3 years ago
Read 2 more answers
Other questions:
  • 5+15x=5( ) I'm not writing 20 characters
    13·1 answer
  • Solve x3 = 1 over 8. <br> 1 over 2 <br> ±1 over 2 <br> 1 over 4 <br> ±1 over 4
    13·1 answer
  • Write an equation of a line parallel to line EF below in slope-intercept form that passes through the point (2, 6).
    8·1 answer
  • My last function question. Please break this down for me. Brainliest answer will be given
    10·1 answer
  • Fill in the blank with a constant, so that the resulting expression can be factored as the product of two linear expressions: 2a
    9·1 answer
  • A cereal company is creating new boxes for its product. In order to display the boxes, the stores they sell to require that the
    9·1 answer
  • What is the value discriminate b squared -4 AC for the quadratic equation zero equals negative 2X squared minus 3X +8 and what d
    9·1 answer
  • Add (2p4 - 6p2 + 6p3) + (8p + 3p3 + 5p2) =
    6·2 answers
  • Find measure angle B
    9·1 answer
  • There are 516 calories in six ounces of a certain ice cream. How many calories are there in one pound?
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!