Differential encoder output of PSK modulation input
You seem to have a binary system. This is how I would solve it. First, assume a "dummy" inital input and output of 0; then, if the current input is different from the previous input, output a 1; otherwise output a 0. It may be easier to place the data vertically:

input output
----- ------
      0
0     0
1     1
1     0
0     1
0     0
1     1
0     1
1     1
0     1
0     0
0     0
1     1
1     0
1     0


The sequence in your professor's answer looks wrong given the context. However, the reason they may be using 1 and -1 is that, in BPSK, a bit '1' is mapped to a positive amplitude V, and a bit '0' to a negative amplitude -V. The professor seems to have incorporated this step into their solution.