input: Write a function to merge two lists of integers into one sorted list without using the in-built sort function. The function should return the sorted merged list. Use any suitable algorithm to achieve the sorting.
  
  assert merge_two_lists([3, 5, 9, 1, 8], [4, 11, 7, 2]) == [1, 2, 3, 4, 5, 7, 8, 9, 11]
  assert merge_two_lists([], [2, 3, 1]) == [1, 2, 3]
  assert merge_two_lists([5, 4], []) == [4, 5]
  assert merge_two_lists([1, 1, 1], [1, 1, 1]) == [1, 1, 1, 1, 1, 1]
  assert merge_two_lists([], []) == []
output: def merge_two_lists(list1, list2):
      merged_list = []
      i, j = 0, 0
      while i < len(list1) and j < len(list2):
          if list1[i] < list2[j]:
              merged_list.append(list1[i])
              i += 1
          else:
              merged_list.append(list2[j])
              j += 1
      while i < len(list1):
          merged_list.append(list1[i])
          i += 1
      while j < len(list2):
          merged_list.append(list2[j])
          j += 1
      return merged_list