Given a single Linked list with lakhs of nodes and length
unknown how do you optimally delete the nth element from the
list?
first create the list of unknown length..... then get the position of the element to be deleted from the user.... the start travelling in the list.... if it encounters the position prescribed by the user ... get the addresses in the list and shift that to the previous node and free this node........
thank u
| Is This Answer Correct ? | 2 Yes | 1 No |
What does the c preprocessor do?
What are the 4 types of organizational structures?
what will be the output of this program? #include<stdio.h> #define cube(x) x*x*x void main() { int i,j=5; i=cube(j+3); printf("i=%d",i); }
pgm to find any error in linklist(in single linklist check whether any node points any of previous nodes instead of next node)
The % symbol has a special use in a printf statement. Explain how would you place this character as part of the output on the screen?
To what value do nonglobal variables default? 1) auto 2) register 3) static
What is the Difference between Macro and ordinary definition?
3 Answers Bosch, Cognizant, College School Exams Tests, Motorola,
count the numbers between 100 and 300, that star with 2 and ends with 2
how to swap 4 number without using temporary number?
How do you do dynamic memory allocation in C applications?
what is the coding of display the factorial of a number using array and function?
which one of follwoing will read a character from keyboard and store in c a)c=getc() b)c=getchar() c)c=getchar(stdin) d)getc(&c) e)none