Question 1178383: how many distinct solutions (a,b,c) are there to the equation a^2+bc=b^2 if a,b,and c are integers between 1 and 5 inclusive?
Answer by math_helper(2461) (Show Source):
You can put this solution on YOUR website! (2,4,3) is the only solution I found
I re-arranged the equation to and then used this Perl script to do a brute-force check (a,b,c)=($i,$j,$k):
perl -e 'for($i=1;$i<=5;$i++) { for($j=1;$j<=5;$j++) { for ($k=1;$k<=5;$k++) { if (($j-$i)*($j+$i) == ($j)*($k)) { print "$i $j $k\n"; } } } }'
|
|
|