Al Sweigart on Nostr: I hate "code snippets", the code examples in books and tutorials that leave out ...
I hate "code snippets", the code examples in books and tutorials that leave out import/include statements and other "minor" details which make them impossible to actually run.
One benefit of having runnable examples is that the author can copy/paste the code and easily make them into unit tests.
I'm finding SO MANY typos in the draft of the 3rd edition of Automate the Boring Stuff.
Published at
2024-08-09 15:11:29Event JSON
{
"id": "f3ed2c8e851789c703f61a89d2335214657068c7795207376a00bc833357e5a5",
"pubkey": "89fa96909d343cbebf889f13192e30719623c5102393440d15d51d4b2c08f094",
"created_at": 1723216289,
"kind": 1,
"tags": [
[
"proxy",
"https://mastodon.social/users/AlSweigart/statuses/112932702742770645",
"activitypub"
]
],
"content": "I hate \"code snippets\", the code examples in books and tutorials that leave out import/include statements and other \"minor\" details which make them impossible to actually run.\n\nOne benefit of having runnable examples is that the author can copy/paste the code and easily make them into unit tests.\n\nI'm finding SO MANY typos in the draft of the 3rd edition of Automate the Boring Stuff.",
"sig": "8e58e348dfb4509b44d90837e2a2bfaf81a411f9c75fa10927625d006eaa33059162769d39f11813e2761288a7273adb9d5bdfb935759343c5cc275da9a7fdb0"
}