Working from home has become much more common over the past few years, even before the COVID-19 pandemic struck. But whereas doing so was a choice before, now it is mandatory for many office workers. Working from home can be a challenge, though. Yes, it’s great to work in your pajamas and not have to shave regularly, but it comes with some pitfass as well. In this article I will share some tips I’ve picked up from having spent half of my 25 year career working from home.
Managing data almost always involves working with hierarchical or nested data. Whether we are talking about nested files and folders, product categories and sub-categories, music, ... you name it. But we store data in a database in a flat structure. This makes sense because the data objects themselves share the same attributes and it makes for easy searching. But how we store the data and how we need to visualize and manipulate it don't necessarily match. So how do we efficiently transform a flat array to a tree? Day 5 of 30 Days of Algorithms will present one solution with O(n) complexity.
I apologize in advance for the length of this article and the sometimes meandering path it takes. I found this was not only a difficult article to write, and list of skills to compile, but also a difficult article to organize. I hope you find it useful.
While working on a project for work today, I encountered a problem that I apparently have never encountered before. What I thought was a very simple function call in jQuery turned out to be a bit more complicated. I needed to removed an HTML element from a string representation of an HTML snippet. jQuery doesn’t quite behave the way I expected and I had trouble finding a solution.