Forwarded from mivik::channels::tech
但很遗憾被 std(或许应该叫 stl 来着) 吊着锤了
测试代码:https://paste.ubuntu.com/p/YbhnC5qXqV/
测试代码:https://paste.ubuntu.com/p/YbhnC5qXqV/
Forwarded from 「VoP」維尼之聲 - Voice of Pooh🔊
谷歌今年又在直播圣诞老人,点此访问圣诞老人追踪网站:santatracker.google.com
在本信息发表时,圣诞老人已经离开中国
本次圣诞老人仅拜访中国大陆的香港市、长沙市、上海市、重庆市、西安市、北京市、呼和浩特市,其他地区的读者请吃掉为圣诞老人准备的牛奶🥛和曲奇🍪,并上床不等了睡大觉。
#圣诞节 #轻松一刻
在本信息发表时,圣诞老人已经离开中国
本次圣诞老人仅拜访中国大陆的香港
#圣诞节 #轻松一刻
#Python 草,竟然支持“多行”lambda (其实只是多行表达式……
from oslash import put_line, get_line
啊不对,没有 def …… 直接 main=(x:IO)
from oslash import put_line, get_line
def main(): return get_line() |(lambda s: put_line(s)) 啊不对,没有 def …… 直接 main=(x:IO)
Forwarded from dnaugsuz
类型签名上检查器它无法重载 Optional[T] 的 None 和 T 情况啊…… 对它来说只是限制用户可不可以传 None 而已
而且 PY 好像也不太重视 _Noreturn 的 (nonlocal)jump 执行情况
而且 PY 好像也不太重视 _Noreturn 的 (nonlocal)jump 执行情况
Forwarded from Hung-I Wang
dbrattli/OSlash: Functors, Applicatives, And Monads in Python
https://github.com/dbrattli/OSlash
https://github.com/dbrattli/OSlash
GitHub
GitHub - dbrattli/OSlash: Functors, Applicatives, And Monads in Python
Functors, Applicatives, And Monads in Python. Contribute to dbrattli/OSlash development by creating an account on GitHub.
Forwarded from Hung-I Wang
那有没有 Allow writing class types as {a: int, b: int} (
Forwarded from dnaugsuz
https://github.com/duangsuse-valid-projects/Share/blob/master/Others/fill_template.py 我也是2空格。 不用 tab 是觉得语义不好,而且很多默认/强制4空格渲染的;不用4空格是嫌浪费行长,无意义
GitHub
duangsuse-valid-projects/Share
🐕 duangsuse's shared files(e.g. productive software projects, documents) - duangsuse-valid-projects/Share
Forwarded from dnaugsuz
那个…… 提几个建议
1.不要再起 n:str 了,红姐也有这种习惯,换 s:str 或 name:str 吧,激进一点也可以叫 sKey
同理激进命名也可以前置 mainf 的 f, 并精确为 fpOrigin
2.retrun tuple 的时候可以加括号;局部赋值 unpack 时也可以
3.Entry.__lt__(other:str) 序运算符解析了其上 value ,也可以在 ctor 里缓存下
4.s.split(' ',limit=1) 可以抽提下
5.我知道 write_main 里面你 .value[:-1] 是 .rstrip('\n') 的意思+必然存在断言,但即便你能断言,原本的逻辑最好还是注释下,编程中这类“优化”还挺多的,得注意
1.不要再起 n:str 了,红姐也有这种习惯,换 s:str 或 name:str 吧,激进一点也可以叫 sKey
同理激进命名也可以前置 mainf 的 f, 并精确为 fpOrigin
2.retrun tuple 的时候可以加括号;局部赋值 unpack 时也可以
3.Entry.__lt__(other:str) 序运算符解析了其上 value ,也可以在 ctor 里缓存下
4.s.split(' ',limit=1) 可以抽提下
5.我知道 write_main 里面你 .value[:-1] 是 .rstrip('\n') 的意思+必然存在断言,但即便你能断言,原本的逻辑最好还是注释下,编程中这类“优化”还挺多的,得注意