dp of length n with all elements set to 0. dp[0] is set to 0 since we start in room 0 on day 0.n-1.i, calculate dp[i] based on the following rule:
nextVisit[i-1] is i-1, we need 2 more days to visit i from i-1.nextVisit[i-1] and then return to i-1 and finally to i.dp[n-1] modulo 10^9 + 7.