Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
Q. Write down a programme in C to create a single linked list also write the functions to do the following operations
(i) To insert a new node at the end
(ii) To delete the first node
Ans:
//Create a single list
struct node
{
int data;
struct node *link
}
struct node *p,*q;
//Inserting a node at the end(append)
append(struct node **q,int num)
struct node *temp; temp=*q; if(*q==NULL)
*q=malloc(sizeof(struct node *));
temp=*q;
else
while(temp link!=NULL)
temp=temp link;
temp link = malloc(sizeof(struct node *));
Temp data=num;
temp link=NULL;
//Delete the first node delete(struct node *q,int num)
struct node *temp;
*q=temp link;
free(temp);
an electrical student designed a circuit in which the impedence in one part of a series circuit is 2+j8 ohms and the impedent is another part of the circuit is 4-j60 ohm mm program
In this unit, we learned the data structure arrays from the application point of view and representation point of view. Two applications that are representation of a sparse matrix
Hear is given a set of input representing the nodes of a binary tree, write a non recursive algorithm that must be able to give the output in three traversal orders. Write down an
Q. Describe the basic concept of binary search technique? Is it more efficient than the sequential search? Ans : The bin ary search technique:- This tec
how to define the size of array
algorithm for insertion in a queue using pointers
Define Big Theta notation Big Theta notation (θ) : The upper and lower bound for the function 'f' is given by the big oh notation (θ). Considering 'g' to be a function from t
Game trees An interesting application of trees is the playing of games such as tie-tac-toe, chess, nim, kalam, chess, go etc. We can picture the sequence of possible moves by m
Conceptually, the stack abstract data type mimics the information kept into a pile on a desk. Informally, first we consider a material on a desk, where we might keep separate stack
extra key inserted at end of array is called
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd