top | item 41450660

Layman's Guide to Python Built-in Functions

50 points| rbanffy | 1 year ago |mattlayman.com

22 comments

order
[+] smarx007|1 year ago|reply
"Layman's Guide" ... Matt Layman

This is The ultimate clickbait. Bravo!

[+] extraduder_ire|1 year ago|reply
A name up there with Matt Godbolt's in being incredibly apt and sounding made up.
[+] maw|1 year ago|reply
Fortunately his surname is not Deacon.
[+] throw_a_grenade|1 year ago|reply
Some of that looks incorrect

> all returns True if all elements in something list-like (such as a list or tuple) are “truthy.” If any element is false or if the list is empty, it returns False.

  Python 3.11.2 (main, Aug 26 2024, 07:20:54) [GCC 12.2.0] on linux
  Type "help", "copyright", "credits" or "license" for more information.
  >>> all([])
  True
[+] wakawaka28|1 year ago|reply
To be honest I hate searching for docs on built-in Python functions. The reference is actually hard to navigate and it seems to spread this information out. Thanks for this.
[+] zt1123G|1 year ago|reply
Simple concepts, explained daily on HN as long as it's Python. This marketing is how the language got big.
[+] fuzztester|1 year ago|reply
raise UnGrokkableStatementException(";)")
[+] rednafi|1 year ago|reply
It’s a great language overall. If it ever gets half as fast as Go, it’s going to be game over for many other high level languages.
[+] rednafi|1 year ago|reply
AsyncRange already has an __aiter__ method defined. So the aiter(…) in the for-loop is redundant.