def arithmetic(a, b, operator):
    """
    Take two integers and perform a math operation on them depending on the operator input.
    :param a: positive integer.
    :param b: positive integer.
    :param operator: string of four operators: "add", "subtract", "divide", "multiply".
    :return: the result of the two numbers having that operator used on them.
    """
    if operator == "add":
        return a + b
    elif operator == "subtract":
        return a - b
    elif operator == "multiply":
        return a * b
    else:
        return a / b