美文网首页
Python 13 Programming Tutorial

Python 13 Programming Tutorial

作者: 豆表示低调 | 来源:发表于2016-08-30 14:41 被阅读0次
def allowed_dating_age(my_age):
    girls_age = my_age/2 + 7
    return girls_age

buckys_limit = allowed_dating_age(27)
creepy_joe_limit = allowed_dating_age(49)
print("Bucky can date girls", buckys_limit, "or older")
print("Creepy Joe can date girls", creepy_joe_limit, "or older")

'''
*** Challenge 2 ***
Display a list of the dating limits for guys 15-65 years old
Good luck!
'''

相关文章

网友评论

      本文标题: Python 13 Programming Tutorial

      本文链接:https://www.haomeiwen.com/subject/tfvfettx.html