Find the middle node in the linked list??
(Note:Do not use for loop, count and count/2)
Answer Posted / santhoshr
It wont work exactly if the no of nodes is not given!!! So
better answer is having two pointers from first itslf.
And like this , another question is there,
to find the pth node from last!! That too haas the same logic!!!
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
How can a program be made to print the name of a source file where an error occurs?
Describe the complexity of Binary search, Quicksort and various other sorting and searching techniques..
What is c definition?
Explain what is the difference between text files and binary files?
program to find error in linklist.(i.e find whether any node point wrongly to previous nodes instead of next node)
Do string constants represent numerical values?
Which are low level languages?
If i have an array 0 to 99 i.e,(Size 100) I place the values 1 to 100 randomly like a[0]=29,a[1]=56 upto array[99].. the values are only between 1 to 100. getting the array values by using scanf.. If i entered one wrong element value line a[56]=108. how can i find it.. and also how to find the missing value in 1 to 100.. and i want to replace the missing values.. any one of them know please post your answer..
What is the difference between volatile and const volatile?
Why & is used in scanf in c?
The performance of an operation in several steps with each step using the output of the preceding step a) recursion b) search c) call by value d) call by reference
what do u mean by Direct access files? then can u explain about Direct Access Files?
GIVEN A FLOATING POINT NUMBER HOW IS IT ACTUALLY STORED IN MEMORY ? CAN ANYONE EXPLAIN?? THE 32 BIT REPRESENTATION OF A FLOATING POINT NUMBER ALLOTS: 1 BIT-SIGN 8 BITS-EXPONENT 23 BITS-MANTISSA
Why is %d used in c?
#include main() { enum _tag{ left=10, right, front=100, back}; printf("left is %d, right is %d, front is %d, back is %d",left,right,front,back); }