solution for merge 2 sorted linked lists