Hacker News new | ask | show | jobs
by wskinner 2871 days ago
I store physical items in my home in an LRU cache. Items I use all the the time are close to the places where I use them. Less frequently used items are stored further from the place they are used, for example in a closet or the garage.

This clashes badly with my roommate, also a programmer, who strongly prefers to store items by category. He will put all the kitchen gadgets on a shelf by the kitchen even if those gadgets go months without being used.

The advantage of his method is that you always know where something is, because it’s in the right place. The advantage of my method is that most of the time I get things done faster, though sometimes I end up spending some time looking for a thing I use only infrequently.

It turns out he also has much more stuff than I do. Since caches are more efficient with a smaller working set, it makes sense that we would each prefer our own strategy. Who knows which direction the causation goes.

4 comments

This reminds me a lot of Marie Kondo's book, The Life-Changing Magic of Tidying Up, which had a huge impact on how I organize things.
Also reminds me of Sandra Felton's book The Messies Manual: The Procrastinator's Guide to Good Housekeeping which had a huge impact on my approach to most things in life requiring organization. I'll one-up the idea of an LRU cache: you can own several pairs of scissors. And the right place for them can be the workshop, the sewing room, the art studio room, the kitchen, and your home office. That one tip has saved me loads of time.
I've always done this but I always find my cache being polluted because I didn't estimate the frequency of use correctly. Regular purges are important otherwise it ends up as a fragmented mess.

A good alternative is how I handle my clothes, many would call it a pile but my clothes are stored as a few LIFO stacks, one for work, one for weekends, one for underwear, etc. For work the shirts are all the same so it's just the simplest option, for weekends it works out well because my favorites are always at the top. I suspect most people manage their pantries the same way.

I handle my clothes as a combination of LRU cache in each drawer for clean clothes and min heap for dirty. Ish. I agree with you that most people probably do something like this as well. It’s not rocket science, just computer science.
Came here to say this. My system is basically an LRU cache also. Also I have a storage system that I can lookup anything I need to use (that I don't use often) that is just labelled boxes and database I can string search. This is really related to a kaizen approach to things that I've read about in various books, things that don't get used get sold off.
What an excellent answer!
I have the same problem.

IMHO do both: multiple LRU caches by category.