logo CodeStepByStep logo

parameter_mystery_exam3

Language/Type: Python parameters return

The following console program uses parameters and produces four lines of output. What are they?

def axiom(c, b, a):
    print(a, "+", c, "=", b)
    return a + b

def main():
    a = 5
    b = 1
    c = 3
    three = a
    one = b + 1

    axiom(a, b, c)
    axiom(c, three, 10)
    three = axiom(b + c, one + three, a + one)
    a += 1
    b = 0
    a = axiom(three, 2, one)

main()
line 1
line 2
line 3
line 4

You must log in before you can solve this problem.

Log In

Need help?

Stuck on an exercise? Contact your TA or instructor.

If something seems wrong with our site, please

Is there a problem? Contact us.