On Mondays

I always hear people complaining about Mondays.

In particular, I've heard that it is difficult to work because the energy and motivation levels are "naturally" lower after the weekend.

So strange it sounds every time.

Normally, one should be rested after the weekend, shouldn't they? Just as a bullet has its highest speed right after it has left the barrel.

For me, Monday has consistently been one of the more productive weekdays.

What about you?

Share the joy
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

On bees and flies

Trust me, at your workplace – and in your life in general, but especially at your workplace – it will do you good to always assume the best intentions of people around you.

It's not a big issue if you will be occasionally proven wrong.

A much bigger issue would be a toxic atmosphere of suspicion that you'd create if you adopted an opposite viewpoint.

Some people are like flies, and other people are like bees, Paisios of Mount Athos famously used to say. Whether you pay more attention to flowers or to dumpsters is completely up to you.

Be like a bee. You will be happier.

Share the joy
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

There is a bug...

Steps to reproduce: get into the car, drive to (x, y). The car explodes.

How does one solve the issue?

Junior Developer: spends half a day investigating and still has no clue about the root cause. Writes a patch that makes the car change its trajectory whenever it approaches (x, y). Time spent: 4.5 hours.

Middle Developer: spends an hour investigating. Posts the debris picture on Stack Overflow, where the experts agree that it "certainly looks like a mine". Arms the car with a metal detector and attaches a shiny spring kit that makes the car jump whenever the metal detector goes off. Time spent: 3 hours.

Senior Developer: spends zero time investigating. "Curse it, mines again", he grumbles, and runs an old detection script to collect the coordinates. Upon this, takes a shovel and digs out all the mines one by one until none remain. Time spent: 2 days.

Lead Developer: remembers that suspicious place in the world generation framework that he glanced upon two years ago. Digs into the code and eventually discovers a race condition that leads to mines repeatedly falling down from the sky. Fixes the design problem and clears the mines. Time spent: a week.

Looks like the invested time does not necessarily correlate with the value delivered.

Share the joy
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

The "Have Done" List

One incredibly important insight that I've gained after adopting the GTD approach to my life is as follows. Besides various "to-do" lists, you must maintain, preferably automatically, a "have done" list to review before bedtime.

(or every time you feel like a worthless loser – which is, more often).

I mean, just look at all these enormous "next actions" lists. You close one project, and it immediately entails another one. You tick off an item and feel like a winner for a fleeting moment – but the cunning hydra immediately grows two heads in place of the one you've cut off.

The "next actions" keep adding up.

Munk - Scream

Making a titanic effort, all I have managed to do is to limit the growth. There seems to exist a zero-point energy number of incomplete items, a natural limit that I am not able to break no matter what.

And perhaps that's normal.

But I hoped that getting so many things done was going to make me feel good – and it didn't. Now I seem to understand why.

For God's sake, let your soul rest in peace every night – review the list of the items you've managed to do today. Let yourself understand that you're actually achieving something in this life.

Share the joy
  •  
  •  
  • 1
  •  
  • 8
  •  
  •  
  •  
    9
    Shares

On the limitations of infinities

architecture-635687_1920

– Good afternoon, sir. Welcome to the Hilbert's Grand Hotel, where we take pride in being completely sold out all the time and still being able to accommodate any arriving guest. Can I help you?
– Yes, I'd like a room, please.
– My pleasure! Which room number would you like? Leveraging the power of transfinite sets, you can pick absolutely any one!
– Absolutely any? Are you sure?
– Yes, sir. Which room would it be?
– The last one, please.

Share the joy
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

Three random facts about humanity

Curiosity selfie near the sand dunes on Mars
Selfie of the Curiosity rover (courtesy of U.S. NASA)
  • The closest distance to Mars is 54.6 million kilometers.
  • The diameter of the landing ellipse for the Curiosity rover was 20 kilometers.
  • If the landing site was the size of a dart board (225 mm in diameter), we would be throwing darts at it being 750 kilometers away.

That's the bare minimum you need to know about the current state of our space technology.

 

Share the joy
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

TaskMan v0.3.0 released!

TaskMan v0.3.0 brings along a lot of new features and improvements!

  • Tasks are now displayed in a nice tabular format.
  • You can also output (or import) tasks in XML, JSON, and CSV formats using the --format flag.
  • Several program parameters have become customizable, see taskman config.
  • Multiple task lists are now supported. The current list name is stored in the configuration file and can be changed using config list or list commands. For most operations, the target list name can be specified explicitly using the --list flag.
  • You can also specify (and filter by) task due dates using the --due flag, including a number of natural language dates like today, tomorrow, or this month.
  • Read-Eval-Print (REPL) mode is now supported via taskman repl (no need to type out taskmanevery time).
  • taskman clear is back! Rather than being a separate command, it is now an alias expanding to taskman delete --all --interactive.

Check it out, provide feedback, share with friends!

Share the joy
  •  
  •  
  • 1
  •  
  • 8
  •  
  •  
  •  
    9
    Shares

Russian classics

I have just finished reading Nikolay Gogol's "Dead Souls", which act has only strengthened my belief that Russian classics are, in Shrek's terms, like onion. It is praiseworthy that the first couple of layers are removed at school, but a single reading would never be enough to reach to the pulp with its burning yet curative character.

I remember how we, being nothing more than little kids, treated the poem as a shallow, sketchy comedy with bits of sermon here and there, and hated reading "boring" literary criticism. However, it takes a grown-up to understand and appreciate the piece's contemplative power, and to startle at Plyushkin or Manilov's seeds inside their own soul.

Share the joy
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  

TaskMan learns command line flags

TaskMan v0.2.0 is a major release that marks a number of changes in both TaskMan's philosophy and public interface.

  • The most notable change is the introduction of command line flags. For example, tasks can now be filtered by their completeness, ID, or description; the user can limit the total number of tasks to display, and / or can skip a given number of tasks in the output.
  • With the introduction of filtering flags, the way set and delete commands work has changed: you can now update or delete more than one task at a time. For example, taskman delete -i 5-10 will delete all tasks whose ID is in the range 5 – 10, and taskman delete --like remember will delete all tasks containing the word "remember" in their description.
  • To prevent shooting yourself in the foot, raw taskman delete and taskman update are forbidden without the presence of the --all flag.
  • taskman clear command is not available anymore. A semantically equivalent command is now taskman delete --all.

The release also includes many bug fixes and unit tests that allowed to discover these bugs in the first place.

For more details, see the release's README.md file. The archive can be downloaded here.

Share the joy
  •  
  •  
  • 1
  •  
  • 2
  •  
  •  
  •  
    3
    Shares

C#: get all instance fields of a particular type

While working on TaskMan yesterday, I have encountered the problem of how to get the values for all instance fields of a particular type. Giving more context: the future versions of TaskMan will make extensive use of command line flags. For now, I have made up my mind about only a few of them, and declared each flag as an instance field in my main program class (the Flag<T>  is a simple data structure I use to represent a CLI command flag):

At the same time, for one particular purpose irrelevant to the point of this post, I also needed to collect all flags into a collection of the base class type, Flag :

Of course, at first I wrote something like the following code in the constructor:

It didn't look good enough. First, it smells of ugly code duplication – I essentially declare things twice. Second, it's bug-prone: what if I add another flag and forget to update the collection in the constructor?

So that's what I ended up with, Reflection to the rescue:

Note how concise and human-readable this looks using Linq / Lambda syntax! You can even read it out aloud:

  • We ask the type TaskMan :
  • "Get us all your non-public instance fields,
  • where the field type is assignable to a variable of type Flag ,
  • collect values from each of these fields,
  • and cast them to the Flag type". 

Neat.

Share the joy
  •  
  •  
  • 1
  •  
  • 2
  •  
  •  
  •  
    3
    Shares