In economics the 'opportunity cost' is the cost of a path not taken. If you were presented with a choice such as enter a PhD program or immediately go to work for a consulting firm for $80,000 a year then there's a cost to either path not taken.
If you do the PhD then you've turned down $240,000 of earnings (perhaps because you think you'll earn more in future from the PhD), if you take the job you turn down the chance to get the qualification and hence a higher salary afterwards (the lost increase in salary is the opportunity cost).
Another sort of cost is the cost of paths not observed. I call this serendipity cost.
While working at a start-up I was inundated with email from a variety of sources and wanted to find a solution. While looking for a solution I stumbled upon a project called ifile and decided to walk down its path. That path took me into machine learning and POPFile, meeting Paul Graham and much more. I was looking for a solution to my email overload problem, I found something else.
But there are other times when I paid the serendipity cost by not observing a path. By not observing the lucky randomness in front of me I've cut off various interesting paths that could have been fulfilling both financially and emotionally. And that happened when I got too blinkered about the path I was on. The key to not paying a serendipity cost is to look around the path you are walking for the wonderful things that are adjacent.
Some years ago I was told about some people working on an interesting start-up to keep people in contact with work colleagues. I dismissed the idea as I was somewhat obsessed with the path I was on (which went nowhere). The idea is now called LinkedIn.
If you don't want to pay the serendipity cost then you listen when a little voice says "Now, that's interesting" and not be quick to dismiss the interesting paths leading off around you.
I wonder how things would have been different if Alexander Fleming hadn't looked at those culture dishes and gone "Hmm, that's interesting".