/* Reverse the singly linked list */ #include<stdio.h> #include<conio.h> #include<process.h> struct node { int info; struct node *link; }*start=NULL; void main() { struct node *temp,*q,*p,*t; int n,i,x; clrscr(); printf("\n Enter How many number:-"); scanf("%d",&n); for(i=0;i<n;i++) { temp=(struct node*)malloc(sizeof(struct node)); if(temp==NULL) { printf("\n Insufficient memory"); getch(); exit(0); } printf("\n Enter number:-"); scanf("%d",&x); temp->info=x; temp->link=NULL; if(start==NULL) { start=temp; } else { q=start; while(q->link!=NULL) { q=q->link; } q->link=temp; } } t=NULL; for(i=0;i<...
Always with you to fascinate and feisty you.I'm blessed and I thank God for every day for everything that happens for me.