python中创建函数和调用函数

 

1、

>>> def a():     ## 创建函数
    print("helloworld!")

    
>>> a()
helloworld!      ## 调用函数
>>> 

 

posted @ 2021-03-03 18:52  小鲨鱼2018  阅读(457)  评论(0编辑  收藏  举报