P1.cpp: In function ‘int main()’:
P1.cpp:38:21: warning: for increment expression has no effect [-Wunused-value]
for( int i=1; ;i<=max+1; i++) {if(Tr[i]) ans*= arr[i]; if(ans>1000000007) ans%=1000000007;}
^
P1.cpp:38:28: error: expected ‘)’ before ‘;’ token
for( int i=1; ;i<=max+1; i++) {if(Tr[i]) ans*= arr[i]; if(ans>1000000007) ans%=1000000007;}
^
P1.cpp:38:30: error: name lookup of ‘i’ changed for ISO ‘for’ scoping [-fpermissive]
for( int i=1; ;i<=max+1; i++) {if(Tr[i]) ans*= arr[i]; if(ans>1000000007) ans%=1000000007;}
^
P1.cpp:38:30: note: (if you use ‘-fpermissive’ G++ will accept your code)
P1.cpp:38:33: error: expected ‘;’ before ‘)’ token
for( int i=1; ;i<=max+1; i++) {if(Tr[i]) ans*= arr[i]; if(ans>1000000007) ans%=1000000007;}
^
P1.cpp:31:22: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%lld", &A);
^
P1.cpp:32:22: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%lld", &X);
^