Project Euler #219: Skew-cost coding