Thanks for providing these details.
For your Python example I'd just use a snippet. On the other hand, Google's pretty fast and always updated.
It's all a personal trade-off I guess. I wouldn't say it's common for me to forget I knew something. But maybe the cost of creating, maintaining, and reviewing card decks is worth it for you.