A small programming challenge