我对python很新,碰巧现在已经使用过C#了.我看到有一个与集合一起使用的过滤器方法,它似乎相当于LINQ的where子句.
我想知道,在python中是否还有LINQ的select语句?
示例:my_collection.select(my_object => my_object.my_property)将返回my_collection中每个对象的my_property的集合.
Ign*_*ams 26
[my_object.my_property for my_object in my_collection]
Run Code Online (Sandbox Code Playgroud)