all test cases are not passing
Even after odd linked list
@ayu2321
Your code is giving segmentation fault if all the elements of linked list are either even or odd.
Example:
5
1 1 1 1 1 Your code would not work for such testcases.
So simple add these two lines just after line 56, you code will work
if(a_head==NULL){ return b_head; }
if(b_head==NULL){ return a_head; }
now also all the test cases are not passing
@ayu2321
I can’t see any change in your latest submitted code. please submit this one
I have made change in your code
still not all are passed
@ayu2321
your submission aren’t visible and the same code is working fine on hackerblocks. Can you please submit it on hackerblocks and tell me whethe it’s working there or not. https://hack.codingblocks.com/app/contests/1128/69/problem
