Error Detection

Sir, kindly tell me the error in the following code for the Intersection point of two Linked List problem. Please do not send the corrected code, I just want to know the error. I will try to correct the code myself.

Code:


Question:
https://online.codingblocks.com/app/player/179062/content/174007/5166/code-challenge

hello @gaurisha

    while(temp1->data != temp2->data)
    {
        temp1 = temp1->next;
        temp2 = temp2->next;
    }

here temp1 ,temp2 can be null, u need handle that.
also so many nodes can have same data value , so compare address in place of data

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.

Sir can you please correct the following code. I have been trying it for a long time:

Code: https://ide.codingblocks.com/s/453608

check now->

Sir, still not working. the error is :runguard: warning: timelimit exceeded (wall time): aborting command runguard: warning: command terminated with signal 15

dont run it , it will not run becuase in input box they havent mentioned input as per input format.
direclty submit and see the result

working fine on my side->
ss

Ok sir, got it. Thank you.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.