JustPaste.it
using System;
class Test
{
bool FindMatch(string[] arr) {
string[,] table = {
{"Red", "Blue", "Green"},
{"Monday", "Wednesday", "Friday"}
};
foreach (string str in arr) {
int row, colm;
for (row = 0; row <= 1; ++row) {
for (colm = 0; colm <= 2; ++colm) {
if (str == table[row,colm]) {
return true;
}
}
}
}
return false;
}
static void Main(string[] args) {
if(FindMatch(args))
Console.WriteLine("Found {0} at [{1}][{2}]", str, row, colm);
else
Console.WriteLine("{0} not found", str);
}
}