greedy, math

Level B