#include "stdio.h" struct SNo { int c; SNo * prox; SNo * ant; }; void main() { SNo * no; SNo * i; no = new SNo; no->c = 'A'+4; no->ant = new SNo; no->prox = new SNo; no->ant->c = 'A'+3; no->prox->c = 'A'+25; no->ant->ant = no->prox; no->prox->prox = NULL; no->ant->prox = no; no->prox->ant = no; for( i = no->ant ; i != NULL ; i=i->prox ) { printf("%c",i->c); } printf("\n"); for( i = no->prox ; i != NULL ; i=i->ant ) { printf("%c",i->c); } printf("\n"); }