Пример #1
0
 public int[,] CheckDireccion(char[,] matriz, string word, int row, int col)
 {
     int[,] result = new int[word.Count(), 2];
     if (col - (word.Count() - 1) >= 0)
     {
         for (int offset = 0; offset < word.Count(); offset++)
         {
             if (matriz[row, col - offset] != word.ElementAt(offset))
             {
                 return(next.CheckDireccion(matriz, word, row, col));
             }
             ConvertToResponseExamen(ref result, row, col, offset);
         }
         return(result);
     }
     else
     {
         return(next.CheckDireccion(matriz, word, row, col));
     }
 }
Пример #2
0
 public int[,] CheckDireccion(char[,] matriz, string word, int row, int col)
 {
     int[,] result = new int[word.Count(), 2];
     if (row + word.Count() <= matriz.GetLongLength(0))
     {
         for (int offset = 0; offset < word.Count(); offset++)
         {
             if (matriz[offset, col] != word.ElementAt(offset))
             {
                 return(next.CheckDireccion(matriz, word, row, col));
             }
             ConvertToResponseExamen(ref result, row, col, offset);
         }
         return(result);
     }
     else
     {
         return(next.CheckDireccion(matriz, word, row, col));
     }
 }
Пример #3
0
 private int[,] findWordArray(char[,] matriz, String word, int row, int col)
 {
     return(checkUp.CheckDireccion(matriz, word, row, col));
 }