会员
周边
众包
新闻
博问
闪存
赞助商
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
47759476
Once you get through that terrifying factual and accepting that,then every place is the center of the universe,and every moment is the most important moment and everything is the meaning of life
博客园
首页
新随笔
联系
订阅
管理
2022年11月4日
Python函数参数中的 : 以及 ->
摘要: 一些python函数中,参数后面有冒号,函数后面还有箭头,这是什么含义呢? 函数参数中的冒号是参数的类型建议符,告诉函数调用者希望传入的实参的类型。函数后面跟着的箭头是函数返回值的类型建议符,用来说明该函数返回的值是什么类型。 官方的解释是type hints,是Python 3.5新加的功能,作用
阅读全文
posted @ 2022-11-04 01:51 TR_Goldfish
阅读(665)
评论(0)
推荐(0)
编辑
公告