IRAJ THARAKA HETTIARACHCHIGE •
Back to Blog

Working Night Shifts While Learning to Code

From midnight to 8 AM, I'd work. From 9 AM to 2 PM, I'd sleep. From 3 PM to 11 PM, I'd learn to code properly. Then repeat. For months.

This isn't a humble brag. It nearly broke me. But it's how the transition happened.

The Reality

I don't romanticize this period. It was brutal. I was constantly tired, socially isolated, and uncertain whether any of it would work.

The people who tell you to "just work harder" often haven't actually done it. Sustained effort over months, with no guarantee of payoff, while your body screams for rest - it's not inspirational. It's grinding.

Why It Was Necessary

I'd been playing with computers since I was young - that's what drew me to tech in the first place. But there's a difference between tinkering and professional skills. SLmix had taught me I could build things, but it also showed me how much I didn't know.

I didn't have a computer science degree. What I had was time I could allocate differently than sleep and leisure, and an obsession with technology that had been with me since childhood.

For people with advantages, there are easier paths. For people without, there's usually a period of painful transition. You can resent this or accept it. Accepting it is more productive.

What I Actually Did

The learning wasn't systematic. I didn't follow a curriculum. I built things, got stuck, figured out the specific thing I needed to learn, learned it, and kept building.

Projects included:

  • Terrible websites that technically worked
  • Scripts that automated repetitive tasks
  • Small tools that solved my own problems

None of these made money. All of them built skills that eventually did.

The Compound Effect

Learning to code isn't linear. The first month, you can barely make anything work. The third month, things start connecting. The sixth month, you're dangerous. The twelfth month, you're actually useful.

But you can't skip to month twelve. The frustrating early months are mandatory. Every night shift where I was too tired to think clearly still somehow moved the needle.

What Kept Me Going

I'd love to say it was vision and determination. Mostly it was fear.

Fear of staying in physical labour forever. Fear of my body giving out before I had an alternative. Fear of being fifty years old and still trading hours for money at the same rate.

Fear is an underrated motivator. Not panic - that's paralyzing. But a cold, clear understanding of what happens if you don't change course.

The Turn

Eventually, I got a job writing code. It paid less than my night shifts initially. But the trajectory was different. Every month, I was worth more. Every project taught me something. Every year, my options expanded.

That's the difference between a job and a career. A job pays bills. A career compounds.

What I'd Tell Someone Starting Now

The path is different now. Resources are better. AI tools can accelerate learning. Remote work means more opportunities.

But the fundamental trade remains: if you don't have advantages, you have to create them through effort others aren't willing to expend.

That sounds harsh. It's also liberating. Your outcome isn't determined by your starting point. It's determined by what you're willing to do about it.

The Grind Nobody Celebrates

Social media shows the success. It doesn't show the nights of exhaustion, the moments of doubt, the months where nothing seems to work.

Those invisible months are where the real work happens. Anyone can celebrate a win. Building during the losing period is the actual test.


What are you grinding on right now that nobody sees? What invisible work are you doing?