At 5 it was 8 degrees.
The temperature dropped 4 degrees from 5 to 6, so at 6 the temperature was 8-4 = 4 degrees.
From 6 to 7 it dropped another 5 degrees, so at 7 it was 4-5 = -1 degrees.
From 7 to 8 it dropped 6 degrees, so at 8 it was -1 -6 = -7 degrees.
Then from 8 to 9 it went up 7, so at 9 it is -7 +7 = 0 degrees.