Answer
a = 3
Work Step by Step
Notice that a, a+1, and a+2 are the consecutive integers, with a+2 being the greatest. Therefore:
$a^{2}+(a+1)^{2}=(a+2)^{2}$
Next, we expand the equation above;
$2a^{2}+2a+1=a^{2}+4a+4$
Then, we simplify:
$a^{2}-2a-3=0$
Factoring the equation, we find that:
$(a-3)(a+1)$
Therefore;
$a=3$ (because it cant be negative)