生日快乐歌的代码

生日快乐歌的代码:

def happy(): //定义happy
    print("Happy birthday to you!")


def sing(person): //定义sing
    happy()
    happy()
    print("Happy birthday to you,dear",person + "!")
    happy()


def main(): //最后附上名字,制作成一首生日歌
    sing("***")
    print()
main()

你可能感兴趣的:(python)