def calculate(num1, num2, symbol):
    """
    操作数的计算
    :param num1:操作数1
    :param num2:操作数2
    :param symbol:操作符
    :return:计算后的结果
    """
    if symbol == '+':
        return num1 + num2
    if symbol == '-':
        return num1 - num2
    if symbol == '*':
        return num1 * num2
    if symbol == '/':
        return num1 / num2
    else:
        return None