Code stupid things
Tags: beginners, programming, python
Published: 2022-01-26 04:48:25

Today I’ve watched new [video from CodeBullet](https://www.youtube.com/watch?v=ldaescGA1dY&t=835s): Channel that I found when I had a huge phase on watching everything AI - be it teaching a neural network to play a Mario game or drive a simple car... anything like that, and CodeBullet provided me with exactly such a material: simple or not so simple task with an interesting enough narration. 

The video was about creating a simple program to cheat in “Clicker Heroes” game. While I don’t know this game, and didn’t want to download it, it reminded me a little bit of an old in-browser clicker game called [“Cookie Clicker”](https://orteil.dashnet.org/cookieclicker/). There was a time when I spent too much time there, so I was happy to notice it’s still up and online as of writing this post.

## What is this about, really?

After finding the game again I realized that I’m curious about my ability to code something like this: simple clicker to cheat the game, as a fun project. 3 AM be damned, I took a laptop and started coding. Finding whether I was in a game, clicking a cookie, check for upgrades and buying them... all of that in a language I didn’t touch in a long while: Python. 

Two and a half hours later, and the code - as simple and unpolished as it is - is done and working. Cookies are clicked, upgrades are being bought and I can watch and smile, as I see my code working without problems.

## And then I remembered.

Coding used to be really fun for me. Such small projects, just to achieve simple objective, overcome a simple challenge. For the last two and a half years of my professional career, I stopped coding just for fun. Projects like this weren’t really in my head, while I had to focus on building my independent life which I’ve then just begun and code I was working on at any company I was currently working at. 

My point is, I forgot that I’ve got into coding to have fun; To overcome those little challenges, to see my work come to any kind of fruition. Of course, there were other sources of motivation, biggest of which was my desire to make people’s life easier using what I have learned, but this? This is where it all started. Simple pleasure from fulfilling a simple task using code. 

## Remember to code small, stupid things.

It’s just never boring. There is always something you can do to just... do a thing. Some stupid challenge, like making your computer react to you in some way. Or any kind of automation, like turning off your console at the specified time in case you left it in rest mode. Or anything else that will probably take you less then two hours, but will flood your brain with dopamine. My point is, remember that coding, like any other work, can be used both professionally and just for fun, for the simple pleasure of Doing The Thing. If you can make your life easier while you do that, it’s just gravy. 

Just remember to have fun. 

PS. For those curious, you can find the code I wrote [here](https://github.com/Hanewali/CookieCheater). Word of warning: It’s not pretty or polished, I’m not a daily Python developer. It was just the easiest language to quickly achieve this objective, and I like writing simple scripts of this kind in Python.