#include using namespace std; #define reep(i,a,b) for(int i=(a);i<(b);i++) #define rep(i,n) reep((i),0,(n)) bool check(int a,int b){ if(0<=a&&a<4&&0<=b&&b<4) return true; return false; } int main(){ vector> vv(4,vector(4)); rep(i,4){ rep(j,4){ vv[i][j]=i*4+j+1; } } vv[3][3]=0; vector> ww=vv; rep(i,4){ rep(j,4){ cin>>ww[i][j]; } } bool ok=true; int x=3; int y=3; int dd[]={1,0,-1,0,1}; // int cnt=0; while(ok){ // cout<