Lines 321-322:

You don't have to divide by `2` twice. Factor it out.