c – when the user enters the line and the column should appear the number that she chose in the matrix

staff & # 39; m good night making a toy system that simulates a theater to study in college, but I'm
In the case of a problem, I ask for the coordinates for the user, the row and the column, but in the confirmation message
and in the case of a problem,
that has nothing to see and numbers until they exceed the matrix, and that is what is missing to finalize my sisteminha.
if someone can help me solve this problem follow the following code vlw:

# include 

int int., int int, int int.
void edit (int sort, int cont);
void called Spring ();
void SadeiraNum (); // declares the function that fills places with numbers
void panel (); // declares the function that the matrix shows
void purchase (); // declares the function that makes the purchase of seats
void cad ();
int matrix[linha][coluna]//
FILE * pointerFile;
Registration structure {
char name [50];
char cpf [15];
char email [30];
};
struct record aux;

int main () {noun
int option = 0;
int l;
int c;
char names[30];
char timeStr[9];

struct tm * data_hours_atual;
time_t seconds;
time (and second);
data_hora_atual = localtime (& seconds);

SillaNum (matrix); // here complements the sillaNum () function; placing the numbers.

the {
// from here and shown to the user the main program options
of the system ("cis");
printf (" n  n MENU  n  n");
printf ("1- Reserve Chair  n");
printf ("2- Show the posts panel  n");
printf ("3- Drawing  n");
printf ("4- EXIT  n");
printf ("option:");
scanf ("% d", and option);

switch (optional) {
case 1:
of the system ("cis");
(CAD);
getch ();
of the system ("cis");
(before choosing the place before and call the matrix and the user can see the panel, even with the purchased theater places updated.

text:
printf (" n  nDigit the Desired Chair line:");
scanf ("% i" & l);
printf (" n  nDigit the Desired Chair Column:");
scanf ("% i", and c);

((l <= 2) || (l<=0) || (l>eleven)) {
printf ("This chair is busy, or does not exist! Choose another!  n");
goto text;
getch ();
}
if ((l <= 2) && (c)<=6)){
        printf("Esta cadeira esta ocupada, ou nao existe! Escolha outra!n");
        goto texto;
        getch();
      }
    else if((c>11) || (C<=0)){
        printf("Esta cadeira esta ocupada, ou nao existe! Escolha outra!n");
        goto texto;
        getch();
      }
    else if ((matriz[l][c]==222) || (matriz[l][c]==0) || (matriz[l][c]==333)){
        printf("Esta cadeira esta ocupada, ou nao existe! Escolha outra!n");
        goto texto;
        getch();
    }
    else (printf(" n"));

        compra(l,c);//a variavel l e c salva na matriz principal o lugar escolhido 

      //abertura de arquivo e leitura
      ponteiroArquivo=fopen("arquivo.txt","r"); 
      fgets(nomes,30,ponteiroArquivo);

      fclose(ponteiroArquivo);
      system("cls"); 

     _strtime( timeStr );
      printf_s( "tParabens %s pela sua compra no dia %d/%d/%d as %s nnSeu ticket sera enviado por e-mail!!n",aux.nome, data_hora_atual->tm_mday, data_hora_atual-> tm_mon + 1 data_hora_atual-> + tm_year 1900 timeStr);
printf ("your seat and% d  n", matrix[c][l]);
system ("pause");
to break;

case 2:
of the system ("cis");
of the system ("cis");
panel (matrix); // call the panel function that contains the array
printf (" n  n");
system ("pause");
to break;

case 3:
of the system ("cis");
chamaSorteio ();
system ("pause");
to break;

// the user choosing this case the program returns nothing and closes
case 4:
return 0;
to break;

default:
printf ("INVALID OPTION !!!  n");
system ("pause");
to break;
}

} While (1 == 1);

system ("pause");
return (0);
}

// this and the function responsible for filling all the places of the theater with numbers!
void SillaNum () {
int c, l;
int in one;
a = 1;

is (l = 1, l <= line; l ++)
for (c = 1, c <= column; c ++) {
matrix[l][c]= A;
a ++;
}
matrix[3][1]= 333;
matrix[3][2]= 333;
matrix[3][3]= 333;
matrix[3][4]= 333;
matrix[3][5]= 333;
matrix[3][6]= 333;
/ ** /
matrix[1][1]= 222;
matrix[1][2]= 222;
matrix[1][3]= 222;
matrix[1][4]= 222;
matrix[1][5]= 222;
matrix[1][6]= 222;
matrix[1][7]= 222;
matrix[1][8]= 222;
matrix[1][9]= 222;
matrix[1][10]= 222;
matrix[1][11]= 222;
/ ** /
matrix[2][1]= 222;
matrix[2][2]= 222;
matrix[2][3]= 222;
matrix[2][4]= 222;
matrix[2][5]= 222;
matrix[2][6]= 222;
matrix[2][7]= 222;
matrix[2][8]= 222;
matrix[2][9]= 222;
matrix[2][10]= 222;
matrix[2][11]= 222;   

}

// this and the function that creates the rows and columns of the parent theater
void panel () {

int c, l;
printf (" n OCCUPANCY PANEL n n");
printf ("");

for (c = 1, c <= column; c ++)
printf (" t% d", c);

is (l = 1, l <= line; l ++) {
printf (" n n t% d", br);
for (c = 1, c <= column; c ++)
yes (matrix[l][c]== 222) {
printf (" t (R)");
} else if (array[l][c]== 0) {
printf (" t (C)");
} else if (array[l][c]== 333) {
printf (" t (D)");
}} else printf (" t (% d)", array[l][c]);

}
(c) – Preferred Seat (C) – CHAIR BUYED (R) CHAIR RESERVED n ");
}

// function that marks in the chosen place the value 0 saving the place
void purchase (int l, int c) {f}

matrix[l][c]    = 0;

}
void cad () {vb}

ponteiroArquivo = (fopen (".txt", "el")); // "a" - create a new file, or modify an existing one.
getchar ();
printf (" t  t WELCOME TO THE UNIP THEATER!  n  n");
printf ("Before buying the chair we are going to make a brief record ........  n  npresssione ENTER to continue ......  n  n  n");
getch ();
printf ("Enter your name:");
fgets (aux.name, 50, stdin);

getchar ();
printf ("Enter your CPF:");
fgets (aux.cpf, 15, stdin);

getchar ();
printf ("Enter your email:");
fgets (aux.email, 30, stdin);

// recording with fprintf in the file
printf (" n");

fprintf (pointerFile, " n ------------------------  n");
fprintf (pointerFile, "name:% s  n", aux.name);
fprintf (pointerFile, "CPF:% s  n", aux.cpf);
fprintf (pointerFile, "Email:% s  n", aux.email);

fclose (fileFile); // close the file

}
() {} ()
int i;
Spanish[4];

srand (time (NULL));

printf ("--------- | DRAW  n  n");

for (i = 0; i <4; i ++) {
stretched[i] = minimum_value + rand ()% (maximum_value-minimum_value);
yes (i == 0) {
edition (drawn[i]I);
}
} else {
stretched[i] = valid (drawn[i], Drawn, i);
edition (drawn[i]I);
}
}
printf ("------------------------------------------");
getch ();
printf (" nParaben to all the winners !!  n  n");
getch ();

}

(in an int, an int, an int, an int)
Spanish

is (aux = 0, aux <contains; aux ++) {
while (== * a (+ aux f)) {
a MINVALUE + = rand ()% (maxvalue-MINVALUE);
}
}
return in one;

}
void edita (int sort, int cont) {

                printf (" t% d ° award hip user:% .2d  n", cont + 1, sort);        

}