Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write the programs for Linked List (Insertion and Deletion)
operations

Answer Posted / bhargav

In Answer 1 i think there is error in dellast()

void dellast()
{
node *temp,*cur=head;
while(cur->next->next!=NULL) -------> error
{
cur=cur->next;
}
temp=cur->next;
cur->next=NULL;
printf("Deleted item is %d\n",temp->item);
free(temp);
}

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between classifying and sorting?

965


What are the disadvantages of linked list over array?

855


What does enum do?

857


Can tuple be sorted?

863


How is a hashset implemented?

877


What is dangling pointer and how to avoid it?

911


What is difference between list and linked list?

903


Which sorting algorithm is the slowest?

814


Why is concurrenthashmap thread safe?

867


How to do the intersection of two sorted arrays?

966


State the different types of linked lists?

879


in tree construction which is the suitable efficient data structure? (Array, linked list, stack, queue)

1188


Define depth and height of a node?

865


What is peek in stack?

878


Does hashmap preserve insertion order?

840