Apple, Amazon and Starbucks spotlight the challenges of long-term investing, from massive gains to periods of underperformance and tough holding decisions.