๐ก๐ How to Remember Useful Code Snippets to Make Your Code More Pythonic?
Skills:
AI Workflow Automation60%
Key Takeaways
The video discusses ways to remember useful Python code snippets, including using note-taking apps like Quiver and Simplenote, and starting a blog to share knowledge and build a public portfolio.
Full Transcript
hey guys I got this question from MBU on YouTube just gonna read out the questions so if I discover more a more useful pythonic way of doing something for example from your book the book is called Python tricks be sure to check it out it's available on Amazon but it doesn't make sense to use it in any of my current projects to practice how can I remember to use it in the future when it is relevant I have FOMO fear of missing out for that sort of thing so I thought that was a really really interesting question so I want to discuss it in this video now what I would encourage you to do because this is you know it's an understandable sort of fear that you're seeing something cool and you want to remember to actually use it what I would encourage you to do is to have some sort of journal some application I don't think it makes sense for this to be paper-based so I I would do that in in some kind of app that you can just add notes and make them searchable I actually blogged about this in the past I'm just the system that I use and maybe I'll do a video on that in the future just kind of run people through it um there are a couple of options that are really great for software developers and the the tool that I used in the past actually just switch to something else but what I use the password he enjoyed was called is called quiver it's a note-taking app for developers and you can do cool things you can add like little I believe you can do UML diagrams then you can just add code snippets and it's kind of all kind of in there and I I think that is a great choice for for keeping your thoughts around I actually well now a while ago I switched to just an app called simple note and I use that to synchronize my notes across all of my devices you know I have a have them on my phone I have it on my iPad I have it on all of my computers and that way I can always access these notes and I can just drop in a new note and at least at the time quiver didn't do that and I really wanted that functionality because I often you know I go for a walk or I sit down in the morning and I just want to add a quick note and I don't want to necessarily like have to walk up to my computer to do that I just want to you know pull out my phone and do it there so I'm using Simplenote now it's a free app you could just go with your phone snow taking app to be honest doesn't really make a big difference if you want to go nuts with this process it probably also starts some kind of personal wiki you know just spin up some wiki wiki system on on on a web server and could also use that and build a system that you can access from anywhere in the world maybe the user experience won't be that great compared to like a native app on your phone for example and what I would do with that is just at these little snippets you know everything every time you find something cool just take a little note like maybe copy and paste some of that code and just put it in there and make it add some keywords just make it searchable you know add some some things that will allow you to fight this again so if this is about like writing more pythonic code whatever your personal definition of that is then you will be able to search for that and find it again so I would definitely encourage you to do this journaling you know it's it's not but maybe journaling is actually it's not the right word for that kind of system it's more like filing these little things and building up sort of a library of these little snippets and little you know hints that that you can use when you're working on a problem and I've absolutely benefited from that you know it's a lot of times it's like my personal version of Stack Overflow and I just punched something in and and I'm like oh yeah I did that in the past and that way I can find it again another really cool option that you could do here is why not start a blog and actually you know share the things that you found like why not talk about this in public because that has a number of benefits hey you're gonna write down the stuff you're gonna find it again and be it's also gonna be you know it's the office is coming back is gonna be coming back to you it because you're building up a public portfolio and you're kind of showing the world that that you're a great programmer because you're sharing your knowledge and you're sharing that the things that you learned and you know it's just it's just a way for for you to to show that expertise and that you care about your craft because many people just don't so this will put you on top of off the pile in a lot of cases right just make you stick out so I know if you feel comfortable with that I don't do it I sort of you know take the best stuff I learn and then turn that into articles and blog posts but I don't like just you know take notes publicly in that sense maybe I should I don't know but that's definitely not another thing and you could you could do let's see here um and yeah I think that that's covered my system or the system that I use so yeah definitely use some kind of app throwing notes in there and then that way you can find them again so yeah let me know how that goes you know leave a comment if you if you see that if you watch this video and I'd be curious to hear about your experience experience using tools like that or just using workflows like that all right take care and happy Pythian ii
Original Description
https://dbader.org/python-tricks โบ This is an ongoing experiment: Make your code more Pythonic with short & sweet code examples
Have you ever encountered a Python code example you had no immediate use for but you really wanted to remember it because it seemed useful?
In this video I'll reply to a question about remembering Pythonic code snippets and other code examples I got on YouTube from ambiyou:
"If I discover more useful pythonic way of doing something (eg from your book) but it doesn't make sense to use it in any of my current projects to practice, how can I remember to use it in the future when it is relevant? I have FOMO for that sort of thing."
Super interesting question and in my answer I'm sharing how I approach this problem in my life as a Python dev. This is also useful if you're learning Python right now and you're struggling to remember everything you've learned so far.
Links I mentioned in the the video:
- https://dbader.org/blog/keep-journals-to-become-a-better-developer
- https://dbader.org/blog/rubber-ducking-journal
- Quiver: The Programmer's Notebook -- http://happenapps.com/
- https://simplenote.com/
- Also great: http://brettterpstra.com/projects/nvalt/ (integrates with SimpleNote for syncing notes)
- Set up a "personal wiki": https://github.com/django-wiki/django-wiki
- https://dbader.org/blog/3-reasons-why-you-need-a-programming-blog
FREE COURSE โ "5 Thoughts on Mastering Python" https://dbader.org/python-mastery
SUBSCRIBE TO THIS CHANNEL: https://dbader.org/youtube
* * *
โบ Python Developer MUGS, T-SHIRTS & MORE: https://nerdlettering.com
โบ PythonistaCafe โ A peer-to-peer learning community for Python developers: https://www.pythonistacafe.com
FREE Python Coding Tutorials & News:
ยป Python Tutorials: https://dbader.org
ยป Python News on Twitter: https://twitter.com/@dbader_org
ยป Weekly Tips for Pythonistas: https://dbader.org/newsletter
ยป Subscribe to this channel: https://dbader.org/youtube
Watch on YouTube โ
(saves to browser)
Sign in to unlock AI tutor explanation ยท โก30
Playlist
Uploads from Real Python ยท Real Python ยท 0 of 60
โ Previous
Next โ
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
A better Python REPL โ bpython vs python interpreter
Real Python
Introducing large-type.com โ A Utility Website
Real Python
Reading Hacker News Without Wasting Tons of Time
Real Python
Forward References and Python 3 Type Hints
Real Python
Using Sublime Text as your Git Editor
Real Python
Python Code Linting and Auto-Complete for Sublime Text
Real Python
Make your Python Code More Readable with Custom Exceptions
Real Python
Write Better Tests with Sublime Text's Split Layout Feature
Real Python
How to Use Sublime Text from the Command Line
Real Python
Rename Variables with Multiple Selection in Sublime Text
Real Python
Sublime Text Settings for Writing PEP 8 Python
Real Python
Write Cleaner Python with Sublime Text's Indent Guides
Real Python
Sublime Text Whitespace Settings for Python Development
Real Python
Function Argument Unpacking in Python
Real Python
Python Code Review: Debugging and Refactoring "Conway's Game of Life" + Automated Tests
Real Python
Using "get()" to Return a Default Value from a Python Dict
Real Python
A Python Shorthand for Swapping Two Variables
Real Python
Python Code Review: Refactoring a Web Scraper, PEP 8 Style Guide Compliance, requirements.txt
Real Python
Click & Jump to Test Failures from the Command Line (iTerm2)
Real Python
Setting up Sublime Text for Python Developers
Real Python
Sublime Text + Python Guide Overview
Real Python
Python Code Review: Adding Pytest Tests to an Existing Python Web Scraper
Real Python
Type-Checking Python Programs With Type Hints and mypy
Real Python
A Shorthand for Merging Dictionaries in Python 3.5+
Real Python
Python Code Review Flask Web Security Tutorial + Virtualenvs, requirements.txt
Real Python
My Python Code Looks Ugly and Confusing โ Help!
Real Python
Setting Up a Programmer Portfolio/Developer Blog โ How To Get Started
Real Python
Do I Need a GitHub/GitLab/Bitbucket Profile as a Developer?
Real Python
Programmer Portfolio โ Example and Walkthrough
Real Python
How to Get Your 1st Speaking Gig at a Tech Conference
Real Python
How to Build Your Public Speaking Skills as a Developer
Real Python
The Object-oriented Version of "Spaghetti Code" is "Lasagna Code" ?!
Real Python
Setting up Sublime Text for Python Developers โ Lesson #1
Real Python
Cool New Features in Python 3.6
Real Python
"is" vs "==" in Python โ What's the Difference? (And When to Use Each)
Real Python
Emulating switch/case Statements in Python with Dictionaries
Real Python
Python Function Argument Unpacking Tutorial (* and ** Operators)
Real Python
What Code Should I Put On My GitHub/GitLab/BitBucket Profile?
Real Python
A Crazy Python Dictionary Expression ?!
Real Python
String Conversion in Python: When to Use __repr__ vs __str__
Real Python
Method Types in Python OOP: @classmethod, @staticmethod, and Instance Methods
Real Python
Optional Arguments in Python With *args and **kwargs
Real Python
Python Context Managers and the "with" Statement (__enter__ & __exit__)
Real Python
Installing Python Packages with pip and virtualenv / venv
Real Python
"For Each" Loops in Python with enumerate() and range()
Real Python
Python Code Review: LibreOffice Automation and the Python Standard Library
Real Python
Managing Python Dependencies With Pip and Virtual Environments โ Lesson #1
Real Python
Python Tutorial: List Comprehensions Step-By-Step
Real Python
Leveraging Python's Implicit "return None" Statements
Real Python
What's the meaning of underscores (_ & __) in Python variable names?
Real Python
Python Data Structures: Sets, Frozensets, and Multisets (Bags)
Real Python
Writing automated tests for Python command-line apps and scripts
Real Python
How to find great Python packages on PyPI, the Python Package Repository
Real Python
Immutable vs Mutable Objects in Python
Real Python
PyPI vs Warehouse, the Next-Generation Python Package Repository
Real Python
pep8.org โ The Prettiest Way to View the PEP 8 Python Style Guide
Real Python
My Experience at PyCon 2017 in Portland
Real Python
Pylint Tutorial โ How to Write Clean Python
Real Python
"Reverse a List in Python" Tutorial: Three Methods & How-to Demos
Real Python
Python Refactoring: "while True" Infinite Loops & The "input" Function
Real Python
More on: AI Workflow Automation
View skill โ
๐
Tutor Explanation
DeepCamp AI