0
Guys, I CAN NOT create a subroutine for the 'e1_insert' function (SECOND SNIPPET). This function will be called every time you want to insert a drink. In this piece of code that I put here, it is only being called to the function choose_estera(SECOND SNIPPET OF CODE) but I do not know how to really call it
The goal of the project is an algorithm that receives products by data types, and stores them, in a STRUCT. The point is that these products can go to two types of mats. In other words, these products will be re-divided according to the treadmill, so I created a strct for each treadmill. In addition this data has to be entered by the user to then be manipulated ... NOTE: IF YOU NEED MORE INFORMATION
void escolhe_estera(int e){
printf("DIGITE '1' para a primeira esteira OU '2' para a
segunda esteira");
scanf("%d", &e);
if(e==1){
// chamo as verificacoes
int b;
e1_insere(b)
}
else(e==2){
e1_insere(int b);
}
}
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
void e1_insere(e1 *f, int b)
{
if(e1_lotada(f) == 1)
{
printf("Erro\n");
}
else
{
f -> topo++;
f -> bebida[f-> topo] = b;
e1_inicia (f);
printf("\nDigite o nome \n");
scanf("%s", &bebida[f->topo].nome);
printf("\nDigite o preco \n");
scanf("%f",&bebida[f->topo].preco);
printf("Digite o volume");
scanf("%f",&bebida[f->topo].volume);
}