void Horiz()
{
int coun, coun1;
coun = 0;
coun1 = 0;
for (int i=0; i<buttons.GetLength(0); i++)
{
for (int j=0; j<buttons.GetLength(1); j++)
{
if (buttons[i, j].Text == "X")
{
coun++;
if (coun == buttons.GetLength(1))
{
Y_Win();
}
}
if (buttons[i, j].Text == "O")
{
coun1++;
if (coun1 == buttons.GetLength(1))
{
B_Win();
}
}
}
}
}