logo CodeStepByStep logo


Language/Type: Python float errors

The following code was intended to print a message, but it actually produces no output. Fix the code to print the expected message.

(The idea here is that the expression 3.2 * 3 in Python does not exactly equal 9.6. You should leave in the computation of the credits variable and should still make your test examine that variable's value, rather than just directly testing the gpa variable itself.)

Function: Write a Python function as described, not a complete program.

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.