#include #include #include using namespace std; const long long delta = 28813; typedef pair pie; #define L first #define R second #define MP make_pair long long a[11][11]; pie next(long long x, long long y, long long sts){ if(sts == 0){ x--; if(x == 0) x = 9; } else if(sts == 1){ y++; if(y == 10) y = 1; } else if(sts == 2){ x++; if(x == 10) x = 1; } else{ y--; if(y == 0) y = 9; } return MP(x, y); } main(){ long long x = 1, y = 1; pie cur; for(long long step=1;step delta) ans %= delta; } } cout<