def move(string, pos1, pos2):
    """
    move position X to position Y means that the letter which is at index X
    should be removed from the string, then inserted such that it ends up at
    index Y.
    """
    new_string = list(string)
    new_string.insert(pos2, new_string.pop(pos1))
    return ''.join(new_string)