/** Program to verify the (incorrect) Fermat's Library tweet: https://x.com/fermatslibrary/status/1813217704905474167 which says: "This is the only solution to a² + b³ = c⁷ in positive integers 15312283^2 + 9262^3 == 113^7" Augh. It uses the new faster sqrtNearestInteger function from the 2024-07-16 release of Frink. */ for seven = 1 to 1001 { n = seven^7 for three = 1 to floor[n^(1/3)] { n1 = n - three^3 two = sqrtNearestInteger[n1] if n1 > 0 and two^2 == n1 println["$two^2 + $three^3 == $seven^7"] } }