MickyOr

Untitled

Nov 24th, 2016
96
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. int Q[8] = {-1,-1,-1,0,0,1,1,1};
  2. int W[8] = {-1,0,1,-1,1,-1,0,1};
  3.  
  4. void dfs(int x, int y)
  5. {
  6.     //.....
  7.     for (int i = 0; i < 8; i++)
  8.     {
  9.         int a = x + Q[i], b = y + W[i];
  10.         //(a,b) es vecino de (x,y)
  11.         /*
  12.         .
  13.         .
  14.         .
  15.         */
  16.     }
  17. }
RAW Paste Data