• + 0 comments

    jump is declared outside of the loop, but is incremented in the loop itself.

    for(int i=0; i<n-1; i++; jumps++)