There is only one test case.
First line, four integers, n, b, c, d.
Second line, n integers, a
0, ..., a
n-1.
1<=n<=10
51<= b, c, d <=10
60<=a
i<=10
6
n lines. i-th line contains one integer,
F(xi-1).
Since the answers may be very large, you should output them modulo 10
6+3.