Coding, from 20 years ago

I was updating a few things in the Todo.txt Android app earlier today. I have a second hand Pixel device that I use for testing as I develop. Since I hadn’t used it for a few days, its battery was fully discharged, and it’d be a short while before I could use it to run and test the code. I had the option of using one of the many software emulators, but they are slow on my system1 when run alongside the Android Studio and multiple Chrome instances. Instead, I decided to just code the stuff, document it, and write a few tests till the Pixel was ready for use.

This was different from my usual development practice of writing a few lines of code and then executing to see if it’s working as expected before continuing. I had to think ahead, and structure the code a bit more. I had to mentally execute the method, and its tests. I wrote a bit more comment docs than usual to account for lack of instant execution confirmation. It felt odd and marginally discomforting at times. But it was fun.

Towards the end of the session, I realised that it was also more productive. I had almost completed two of the three planned updates by end of the hour-long session. Not taking frequent pauses to compile-execute-observe-confirm freed me up to continue planning and coding further and faster. It also stopped me from taking detours on updating unrelated or tangentially-related bits observed in the execution.

The session reminded me of how we used to write code when I was studying engineering. Compiling and executing even our C programs was slow on my PC back then2. So, executing was infrequent, and often followed long periods of writing code, and running through the flow manually multiple times. If the program required internet access, it meant even more coding and manual verification before testing it by execution3. Fond memories :)

Anyway, the Pixel is charged now. I can now test the morning’s code and, if it works, commit it, and move on to the third update.


  1. I use a 2015 MBP, though well specced. It has 16GB RAM, 3.1GHz dual core i7, and 1TB SSD. 
  2. I had a best-amongst-peers custom assembled PC. It had 256MB RAM and 8GB HDD. I can’t recall the processor details, but it was a Pentium II. 
  3. This was after I got a PC. Before that, I’d write the code on one of the PCs in the computer lab, print it on dot matrix printers, and take the printouts back to hostel/home. There I’d go over the code, update it with pen, and then go type it in at the lab the next day to execute and debug. It was more fun than it sounds. 

This weekend

Learnt to use the WordPress.com API with Retrofit. Stumbled over various undocumented quirks of the API. Nearly achieved what I’d started off to do.

Finished (re)reading my favourite Frederik Backman book: My grandmother sends her regards and apologises. I wish I could live in that house in the kingdom of almost awake.

Named one of the flavours of the new app ‘Elsa’. The other flavour is named ‘Granny’, but I might change it to ‘Wurse’.

Dug and relaid the stone tiles in the middle section of the backyard. Weeded the full upper flower bed from end to end. Aireated the rear lawn – one fork pitch at a time!

5+ back breaking, knee stiffening, hand cutting hours in the garden. I could barely move my arms in the shower afterwards.

Rewarded myself by watching a bit of the old sweetheart movie, You’ve got mail.

Now, convinced by Elsa, I’m reading my first JK Rowling book: Harry Potter and the Philosopher’s Stone.

Bon Nuit!

Things I learnt recently

From AD: How to efficiently & quickly dice onions. There’s no magic trick to it, but just knowing the correct technique has made a big difference.
AD studied hotel management at under graduate level, and knows his stuff.

From SD: How to solve a Rubik cube. He lent me his old unused cube and shared a video with the step by step instructions. I’ve gone from taking over an hour to just under 20 mins.
SD solves his cube in under 3 minutes, with a PB of about 1’30”. He knows his stuff.

IMG_20200322_192008.jpg
The first solve. Took me over an hour!

From Sis: How to hang woollens in shallow British closets without the arms hanging out and pushing the door open. Invert the arms so they hang inside the sweater/jacket/hoodie. This reduces the width of the garment, helping it fit comfortably in the shallow closets.

 

From ‘the web’: JavaScript promises and async/await. Learnt, enjoyed, implemented, fell in love with. Promises in Javascript feel as delicious as coroutines in Kotlin.

Friday, the 13th

The dark clouds arrived—Boris returned as PM, winning a big majority, winning a mandate for more lies and bluster for all future elections.

The silver lining faded—Corbyn refused to step down, instead asking for a period of ‘introspection’, and only promising a vague ‘will not lead the party in next election.’ Labour lost 61 seats across the country, and managed to win just one from another party. Labour has now lost two elections in a row under him; elections that any other decent leader would have won comfortably. Still, the ditherer-in-chief says he wants to introspect for a few months to figure out what went wrong!

Then the interesting stuff began.

I published my second Android app: Accelereader for Instapaper. It was in beta for a few weeks, but went into public release earlier this week. It’s always scary publishing publicly, however small the audience may be.

Then I did something even scarier—I decided on the Hanson method for training for the Paris marathon. Even the beginner program has 6 days of running most weeks; I struggle to run 5 days consistently. The beginner program also has almost two months of running 80-90 km per week. My weekly cadence has only rarely been above 50 km. It involves multiple faster-than-race-pace 10-mile tempo runs, and interval sessions that go on longer than my current long weekend runs. I’ll come out of this training season at the top of my running fitness, or broken—mentally and physically.

Not everything is scary. I made progress with the pull-ups. Today I did two full ones. Twice. Last week I was celebrating almost completing one. A few weeks ago I couldn’t even do a quarter. I also do 4-6 chin-ups a couple of times a day, up from just 1-2 a few weeks ago. (Yes, chin-ups and pull-ups are different)

I’ve also made progress with weight loss (despite the muscle gain from pull-ups and running). Yesterday, I weighed-in at 76.2Kg, a nearly 5-year low, and within hitting distance of the goal weight.

And finally, the best bit: I’ve started meditating again. I’m on a 15-day streak, sometimes twice a day, and finally getting back to being able to focus for a few minutes unbroken. If nothing else survives from this period post (I really hope the current government and opposition leadership don’t), I hope at least this will.

Continue reading Friday, the 13th

Me, here, now.

Gardening

After neglecting the garden for 5+ years, I finally started getting my hands dirty this year. It’s been a surprising delight. The flowers are blooming. No plants have died yet. And the weeds are more under control than any time last year. All this for a couple of weekends’ work, and 5-10 mins every morning or evening. My highlight achievement must be saving a few plants from near death—the purple petunias, the value pack bogonias and the medium-sized marigold—and seeing them flourish.

I am really enjoying the work in the garden—probably too much according to R. There must be some truth in what Cal Newport said—the joy of creating physical things with our own hands.

Running

I’ve been running well. I like my current running form, and the times have been reflecting the improvement. I ran my Park Run PB earlier at Woking—22:42. I ran the London marathon earlier in just under 4 hours—3:58:44. This is the first year where I have run at least 100 km every month. It’s also the first year when I’ve run at least once every week. I plan to keep the momentum going through rest of the year.

Reading

Reading has been a continuing theme from last few years. I haven’t read as many fiction books this year as non-fiction. Just haven’t found too many of ones I really want to read. Amitava Ghosh released his new book, Gun Island, so I polished that off in less than a day. But nothing much else.

I’ve read a lot of non-fiction though. Quite a few are based around self-improvement and productivity— Make time, GTD for teens, Digital minimalism, Messy, Range, Sprint, Turn the ship around

I’ve read some books from the running, swimming, cycling, hiking world, but again not as many as I would’ve liked. Goater’s Art of running faster gave some good tips, and Scott Jurek’s North was full of inspiration.

I’ve started listing the books, and notes from some of them on this site.

Head & heart

Parents were planning to visit UK this year. They’ve cancelled. I’m sad.

I stopped meditating regularly months ago. I still meditate occasionally, but without the app there isn’t much to guide me through session after session. Most of the time it is just noticing a breath (tip from Make Time).

The year, mentally, has been a roller coaster. I haven’t really touched the depths of depression like I did around October last year, but I haven’t had many periods of consistent happiness either. I have a feeling it’s all very fragile. Or is it brittle?

Finished Todo.txt for Android

I’m ending the second phase of active development for Todo.txt for Android. All core functionality works sufficiently well for my own use. Dark mode is half baked, so have moved it to the backlog for the next phase, whenever that happens.

Not doing much active development on extensions at the moment.

Next up

Next up is starting a new project, or finding a new role. Either way, it’ll be a time of flux and vulnerability. Tread kindly, por favor!

Continue reading Me, here, now.

Me, here, now.

Finished Todo.txt for Android

I’m at the end of second phase of active development for Todo.txt for Android. All core functionality works sufficiently well for my own use. Dark mode is half baked, so will now be moved to the backlog for the next phase, whenever that happens.

Next few weeks may see small updates to the Chrome extensions—bug fixes and minor tweaks based on user feedback over the last month and a half.

Next up

Next up is starting a new project, or finding a new role. Either way, it’ll be a time of flux and vulnerability. Tread kindly, por favor!

Gardening

After neglecting the garden for 5+ years, I finally started getting my hands dirty this year. It’s been a surprising delight. The flowers are blooming. No plants have died yet. And the weeds are more under control than any time last year. All this for a couple of weekends’ work, and 5-10 mins every morning or evening.

I am really enjoying the work in the garden—probably too much according to R. There must be some truth in what Cal Newport said—creating physical things with our own hands.

Running

I’ve been running well. I really like my current running form, and the times have been reflecting the improvement. I ran my Park Run PB a couple of weeks ago at Woking—22:42. I have been off running so far this week due to an ankle injury picked up on Saturday (thankfully, after I’d completed my 14 mile run). Looking forward to testing the ankle again with a short run later today.

Reading

I’m loving reading ‘Turn the ship around’ by David Marquet. It’s one of those books that is best read in small bits, munched over for a while, then continued. The last book in this category was Daniel Kahneman’s ‘Thinking fast and slow’. They’ll both stay in my forever library, with frequent references to notes and books.

I’m also reading Messy by Tim Harford. This is my active reading book, and will probably be finished tomorrow. It’s an interesting journey of rediscovery. I used to be atypical messy—thriving only in mess and chaos. Working independently forced me to learn discipline and to streamline my life processes. Now I am rediscovering the value of messiness. It’s a brilliant brain tickler for me—harmonising my tidy, streamlined life with a bit of messiness to add some anti-fragility.

The third book I’m currently reading is Sanjaya Baru’s ‘The accidental prime minister’. It’s hard reading, specially because I like the subject. The author covers too much of himself relative to the subject (the prime minister). It also, like bits of ‘Up in the air’, way too frequently delves into explanations and bureaucratic minutae. R tells me it gets better later, so I’m ploughing on.

Continue reading Me, here, now.

Tid bits

Started a new book. And abandoned it within 10 pages. It was a business book with too much ‘values & beliefs’ and barely any nitty gritty of ops and customer service (the reason I picked it).

Lost my phone. And found it within 5 minutes thanks to the new watch. Had kept the phone on a shelf in Tesco while picking something, and forgotten it there. As I moved out of bluetooth range of the phone, the watch lost its connection and buzzed with the notification – reminding me that I’d left the phone behind.

Without being a smart watch, my watch is smarter than me!

Ran a marathon. Not that a 4:36 marathon requires much running. Continue reading Tid bits