Write a pythagorean triplet whose smallest number is 6

so you want

6^2 + b^2 = c^2
b^2 = c^2 - 36

clearly c > 6, so try values of c so when 36 is subtracted from c^2 you are left with a perfect square.
e.g. let c = 7
is 49 - 36 a perfect square ??? nope!
so try c = 8 , etc
should not take you long to find it

what is the sum of first n odd natural number

To find a Pythagorean triplet where the smallest number is 6, we can use the formula for generating Pythagorean triplets:

a = 2mn
b = m^2 - n^2
c = m^2 + n^2

Here, a, b, and c are the three numbers of the Pythagorean triplet, and m and n are positive integers.

We are given that the smallest number is 6, which means a = 6. Let's substitute this value in the formula:

6 = 2mn

Dividing both sides by 2, we get:

3 = mn

Now, we need to find two positive integers m and n whose product is 3. The possible combinations of m and n are (1, 3), and (3, 1).

Let's calculate the values of a, b, and c for each combination:

For m = 1, n = 3:
a = 2mn = 2 * 1 * 3 = 6
b = m^2 - n^2 = 1^2 - 3^2 = -8
c = m^2 + n^2 = 1^2 + 3^2 = 10

For m = 3, n = 1:
a = 2mn = 2 * 3 * 1 = 6
b = m^2 - n^2 = 3^2 - 1^2 = 8
c = m^2 + n^2 = 3^2 + 1^2 = 10

So, the Pythagorean triplets with the smallest number as 6 are (6, -8, 10) and (6, 8, 10). Note that we can ignore the negative sign in b as the length of a side cannot be negative.