K = i + j of assignment 3

Can somebody tell how could the instructor rightly found k is i+j?

Hey…
Which Part are you talking about ?
A code-snippet would be useful…