小猿圈python學習-函數返回值與作用域

函數外部的代碼要想獲取函數的執行結果,就可以在函數裏用return語句把結果返回 def stu_register(name, age, course=‘PY’ ,country=‘CN’): print("----註冊學生信息------") print(「姓名:」, name) print(「age:」, age) print(「國籍:」, country) print(「課程:」, cour
相關文章
相關標籤/搜索