Unintuitive optimization for performing paths union | Hacker News Reader