HOLA A TODOS ME GUSTARIA SABER SI ME PODRIAN AYUDAR A ENCONTRAR EN QUE ES LO QUE ESTOY FALLANDO PORQUE HE TRATADO DE HACER UNA COLA CIRCULAR PERO UTILIZANDO ARRAY Y ME DA 6 ERRORES Y NO LE ENCUENTRO EL PORQUE.
GRACIAS DESDE ANTE MANO.
#include <stdio.h>
#include <conio.h>
#include <iostream>
using namespace std;
#define  MAX_COLA 50
typedef int tipodato;
typedef  struct { 
   int elems;
   int final, frente; 
   tipodato elementos[MAX_COLA];
} colacir;
/*  inicializa la cola */
void crearcola(colacir &cola);
/* retorna el indice del siguiente elemento */
int siguiente(int i);
/* retorna 1 si la cola esta vacia */
int vacia(colacir cola);
/*retorna 1 si la cola esta llena*/
int llena(colacir cola);
/* inserta un elemento al final de la cola*/
void encolar(colacir *cola,tipodato elem);
/* retira el elemento del inicio de la col*/
tipodato desencolar(colacir &cola);
/* obtiene el elmento del inicio de la cola */
tipodato frente(colacir cola);
/* reporta todos los elementos de la cola */
void visualizar(colacir cola);
/** DESARROLLO DE FUNCIONES  **/
void crearcola(colacir &cola)
{ 
   cola.elems = cola.frente = 0; 
   cola.final =MAX_COLA-1;
}
int siguiente(int i)
{   
   return ((i+1) % MAX_COLA);
}
int vacia(colacir cola)
{    
   return (cola.elems == 0);
}
int llena(colacir cola)
{ 
   return (cola.elems == MAX_COLA);
}
void encolar(colacir &cola, tipodato elem)
{ 
   cola.elems++; 
   cola.final=siguiente( cola.final); 
   cola.elementos[cola.final] = elem;
}
tipodato desencolar(colacir &cola)
{ 
   int elem; 
   cola.elems--; 
   elem = cola.elementos[cola.frente]; 
   cola.frente=siguiente(cola.frente); 
   return elem;
}
tipodato frente(colacir cola)
{   
   return cola.elementos[cola.frente];
}
void visualizar(colacir cola)
{ 
   if(!vacia(cola))   
   {       
      cout<<desencolar(cola);
      cout<<"  ";       
      visualizar(cola);   
   }
}
void main()
{ 
   struct colacir C;
   char op;
   int num;
   crearcola(&C);
   do
   { 
      system("cls");
      system("color 09");
      puts("nnntttSIMULACION DE UNA COLA CIRCULAR");
      puts("nnttt1) Agregar un elemento");
      puts("nnttt2) Sacar un elemento");
      puts("nnttt3) Salida"); 
      printf("nntttOpcion: "); 
      op=getche();
      system("cls");
      switch(op)
      {
      case '1': 
         if(!llena(C) )
         { 
            system("color 05");
            printf("nnnnnnttt"); 
            printf("Dato:"); 
            scanf("%d",&num);
            encolar(&C,num);
         }
         else
         { 
            system("color 02");
            printf("nnnntttCola LLena"); 
            getch();
         }
         break;
      case '2':
         system("color 04");
         if(!vacia(C) ) 
            printf("nnnntttDato extraido:  %d",desencolar(&C));
         else
            printf("nnnntttNo hay datos");
         getch();
         break;
      case '3':
         system("color 03");
         puts("nnnntttHASTA PRONTO MIL BENDICIONESnnnnttt");
         break;
      }
   }
   while(op!='3');
   printf("nnttt");
}