[algogeeks] linked lists

2010-10-07 Thread snehal jain
There are two linked list, both containing a character in each node. If one linked list contain characters o x e n c and second contain characters e n c a r t a then the final linked list should contain o x e n c a r t ai.e. if the end of one list is same as the start of second then those

Re: [algogeeks] linked lists

2010-10-07 Thread rahul
How about merge sort. On Thu, Oct 7, 2010 at 1:22 PM, snehal jain learner@gmail.com wrote: There are two linked list, both containing a character in each node. If one linked list contain characters o x e n c and second contain characters e n c a r t a then the final linked list should

Re: [algogeeks] linked lists

2010-10-07 Thread neeraj agarwal
0for this i will search the first element of seconnd list in the first list, when i get it i will make the next of that element in first list to the next of that element in second list. for example l1={a,b,c,d} l2={c,d,e,f} here i will search first element of l2 in l1 here it is 'c' then i

Re: [algogeeks] linked lists

2010-10-07 Thread tech rascal
sorry bt d ques is not clear if first linked list has (a b h g r t s g h) nodes and second linked list has (g r t h s w e r t ) then what should b d result?? On Thu, Oct 7, 2010 at 7:48 PM, neeraj agarwal itsneerajagar...@gmail.comwrote: 0for this i will search the first element of