This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def makeSand(haspb, hasjelly, slicesofbread): | |
breadneeded = 2.0 | |
if haspb == True: #have peanut butter | |
numofsand = slicesofbread/breadneeded #calculate number of sandwich I can make from bread | |
sandtype = "peanut butter" #set default sandwich type | |
if hasjelly == True: #have jelly too | |
sandtype = "peanut butter and jelly" #set sandwich type to include jelly | |
#start counting number of sandwiches I can make |