def merge_helper(arr1, arr2):
    """ Merges two arrays in increasing order
    :type arr1: list
    :type arr2: list
    :rtype: list
    """

    i = 0  # index for arr1
    j = 0  # index for arr2
    ret = list()

    # iterate through both arrays, creating a new list that takes new elements
    # in increasing order
    while i < len(arr1) and j < len(arr2):
        if arr1[i] < arr2[j]:
            ret.append(arr1[i])
            i += 1
        elif arr2[j] < arr1[i]:
            ret.append(arr2[j])
            j += 1
        else:
            # case where both elements are equal, order doesn't matter
            ret.append(arr1[i])
            ret.append(arr2[j])
            j += 1
            i += 1

    # append remainders
    while i < len(arr1):
        ret.append(arr1[i])
        i += 1

    while j < len(arr2):
        ret.append(arr2[j])
        j += 1

    return ret