Python Coding Practice
Working on Python fundamentals.
Rather than writing simplistic functions to solve common coding exercises in a superficial way, I went a little deeper.
I started with a simple set of PyTests and hand-wrote the code (NO AI) to make them pass. This was a good way to clarify the Pythonic way of expressing these concepts. Then I added some more expectations – empty arguments, wrong argument types – and wrote decorators to handle the use cases. I didn’t want the functions to become bloated.
Finally, I moved all the free functions into classes that inherit the decorators from a parent Base class.
The resulting code is clean and DRY.
https://github.com/clockworkpc/codesignal_exercises
Published on 12 Jun 2025
all tags
100daysofcode activerecord android annoyances api apt arch array artix atom az3w backend bash blog browser bug callback career ci-cd cli cloud code coding config configuration cp crud cryptography css csv database db design devops django docker email erp feelsgood filter fugitive gif gist git gnome gnome pomodoro grep hebrew http ide isbn-fetcher iso javascript job search js kanban kindle koans learning linkedin linux logger manjaro map markdown microservices mobi mtp neovim nodejs nvchad packages panda pastbin patch portfolio post postgres pytest python rails reduce refactoring reflections rest routes rspec ruby salesforce script scripting security sed shell sql string_replacement study tdd terminal testing tmux ttd version_control vim vim sort walkthrough webdev workflow zsh