Problem: 106 - Fermat vs. Pythagoras
Problem Definition:
Problem Definition:
-
Fermat's Last Theorem: that there are no integer solutions of
for n >2. -
Given a positive integer N, you are to write a program that computes two
quantities regarding the solution of
where x, y, and z are constrained to be positive integers less than or equal to N. You are to compute the number of triples (x,y,z) such that x<y< z, and they are relatively prime, i.e., have no common divisor larger than 1. - You are also to compute the number of values
such that
p is not part of any triple (not just relatively prime triples).

