rewrite leetcode merge k sorted lists