Ver Mensaje Individual
  #23 (permalink)  
Antiguo 29/07/2013, 21:33
ambigus
 
Fecha de Ingreso: septiembre-2008
Mensajes: 221
Antigüedad: 15 años, 7 meses
Puntos: 1
Respuesta: Guia_Listas_Enlazadas - C++

Me rindo :( NO´se qué hacer :( :( :( :(

Código C++:
Ver original
  1. void Lsec::eliminarNodo()
  2. {
  3.     nodo *aux,*apunt;
  4.     char resp;
  5.    
  6.     apunt=new nodo();
  7.     aux=new nodo();
  8.     aux=inicial;
  9.     cout<<"Entre clave del nodo a eliminar"<<endl;
  10.     cin>>apunt->dato;
  11.     while(aux->sig!=inicial && aux->sig!=apunt)
  12.     {
  13.         aux=aux->sig;
  14.         if(aux->dato==apunt->dato)
  15.         {
  16.             aux->sig=apunt->sig;
  17.             delete apunt;
  18.         }
  19.     }
  20.     cout<<"Listo!!!"<<endl;
  21. }