The old saying, “sleep on it”, meaning spend some time tonight thinking about the question and have an answer tomorrow. It’s a common phrase in our language but how often do you literally put aside time to actually think about it?
Having a busy life outside of work with family, hobbies, dinner, everything else it’s really hard to set aside time to just sit and think. I’ve had to start using the time just before bed, mornings, or go for a walk alone.
Yesterday I was working on a new integration an app we recently launched and I had to work on adding a new API endpoint. It was all really straightforward. However, last night as I was reviewing my day before bed I started thinking about the way I solved the problem and realized I may have made a mistake because I forgot about a constraint from the service that’s going to be reading it. While trying to solve that in my head I realized I solved the entire problem wrong and I should redo my work.
What I do each night is review my day like I was a star in a TV show and I’m following myself around as the cameraman with the goal of looking at my decisions from a different standpoint. This is what helps me attempt to remove my biases, but of course, that doesn’t always work. It is pretty good at allowing me to see mistakes though, and that’s why I do it.
I know many programmers spend their after work hours coding and being on the computer but I implore you to take a break. Get away from the screen and you’ll actually do better work.