C programming

posted by .

Pythagorean Triples.
A right triangle can have sides that are all integers. The set of three integer values for the sides of a right triangle is called a Pythagorean triple. These three sides must satisfy the relationship that the sum of the squares of two of the sides is equal to the square of the hypotenuse.
Find all Pythagorean triples for side1, side2, and the hypotenuse all no larger than 100 using a triple-nested for loop that simply tries all possibilities (“brute-force” computing).

  • C programming -

    Ok, so you need to test all a, b, c from 1 through 100 for a*a + b*b = c*c.

    What point would you like help with?

Respond to this Question

First Name
School Subject
Your Answer

Similar Questions

  1. Maths (V. Hard)

    Firstly calculate how many Pythagorean Triples there are that have no component larger than 300. Next find the sum of all the Hypotenuses from these triples you found in step 1. Finally add together the results that you received in …
  2. tricky math

    consider the right triangle with sides 3,4,5. Notice that the lengths of the sides form an arithmetic sequence. a. determine three other right triangles wtih side lengths in arithmetic sequence. b.let the sides of a right triangle …
  3. math

    The sides of a right angled triangle are x,x+1 and x+2.find x,Am not gettin the right answer. Being a right triangle, x^2 + (x + 1)^2 = (x + 2)^2. Expanding and simplifying, yields x^2 -- 2x - 3 = 0. Factoring or the quadratic equation …
  4. Mathematical Studies

    A right triangle has three sides known to be (x-5) (2x+1) and 2x. By use of the pythagorean theorem show how the sides of the triangle can yield the equation: x^2-14x+24=0 this is my work below: (x-5)^2+(2x+1)^2=2x^2 which expanded …
  5. Algebra

    Need help with these-- 21. Find the possible values of a, of the distance between the points is 5, and the coordinates are (1, 1) and (4,a) 22. The Pythagorean Theorem works only for _______ triangles. Right?
  6. Pythagorean Theorem

    7. The following are the lengths of the sides of four triangles. Which is a right triangle?
  7. math

    the lengths of the three sides of a right triangle R have odd integer values and two of the three sides have lengths 3 and 5. What is one possible length of the third side?
  8. geometry

    Use Pythagorean Theorem to determine which set of sides can be the sides of a right triangle. Question 14 options: a) 3,4,5 b) 4,4,8 c) 6,6,12 d) 8,9,10
  9. Math PLZZ

    1. Which set of numbers represents a Pythagorean triple?
  10. Math Help Please

    1. Which set of numbers represents a Pythagorean triple?

More Similar Questions