yes
also you didnt need to substitute if you think about it, you already had the consecutive pairs
n, n+5, and n+7
n being odd, you are adding 1 to make it even, than another 4
if that isn't divisible, the other pair adds another 2, so it must be divisible if the other wasnt.