CASE 3: Define a function called exactly_one_sauce that returns True if a customer wants either ketchup or mustard, but not both (returns False). Given: def exactly_one_sauce(ketchup, mustard, onion):...


In  python


CASE 3: Define a function called exactly_one_sauce that returns True if a customer wants either ketchup or mustard, but not both (returns False).<br>Given:<br>def exactly_one_sauce(ketchup, mustard, onion):<br>return ketchup and mustard<br>1<br>2<br>print(exactly_one_sauce(True, False, True))<br>print(exactly_one_sauce(True, True, True))<br>print (exactly_one_sauce(False, True, False))<br>print(exactly_one_sauce(False, False, True))<br>print(exactly_one_sauce(True, False, False))<br>print (exactly_one_sauce(False, True, False))<br>4<br>8<br>9<br>

Extracted text: CASE 3: Define a function called exactly_one_sauce that returns True if a customer wants either ketchup or mustard, but not both (returns False). Given: def exactly_one_sauce(ketchup, mustard, onion): return ketchup and mustard 1 2 print(exactly_one_sauce(True, False, True)) print(exactly_one_sauce(True, True, True)) print (exactly_one_sauce(False, True, False)) print(exactly_one_sauce(False, False, True)) print(exactly_one_sauce(True, False, False)) print (exactly_one_sauce(False, True, False)) 4 8 9

Jun 09, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here