Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # E. Given two lists sorted in increasing order, create and return a merged
- # list of all the elements in sorted order. You may modify the passed in lists.
- # Ideally, the solution should work in "linear" time, making a single
- # pass of both lists.
- def linear_merge(list1, list2):
- # +++your code here+++
- return sorted(list1+list2)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement