Task: Program Execution
Input (English): n, t, T, q
Output (English): 4