Problem 223: Almost right-angled triangles I

FCC link

Let us call an integer sided triangle with sides a ≤ b ≤ c barely acute if the sides satisfy a2 + b2 = c2 + 1.

How many barely acute triangles are there with perimeter ≤ 25,000,000?

Test

{{test}}

Console output