Range-based algorithm library