One expression, two kinds of defect

A Python 3 program must divide a 36-dollar bill equally among a positive number of guests, with no extra charges. The variable guests already contains an integer when this statement runs:


Python
print(36 / guests + 2)


Consider separate runs with guests equal to 0 and 4. Select every correct statement.

Choose an answer

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

More Bug Types (Syntax, Runtime, Logic) Questions: