Код: Выделить всё
namespace ConsoleApp2
{
public class program1
{
static void Main(string[] args)
{
string[,] employs = { {"lola", "000"}, {"Neg", "001"}, {"gwen", "010"}
};
string recall = string.Empty;
bool key = false;
do
{
{
string name = Console.ReadLine();
string id_num = Console.ReadLine();
for (int i = 0; i < employs.GetLength(0); i++)
{
for (int j = 0; j < employs.GetLength(0); j++)
{
recall = name == employs[i, j] || id_num == employs[i, j] ? $"Wellcome:{name}" : "name or id is wrong";
key = name == employs[i, 0] || id_num == employs[i, 1] ? true : false;
Console.WriteLine(recall);
}
}
}
} while (key);
}
}
}
Подробнее здесь: https://stackoverflow.com/questions/790 ... in-my-code