http://www.spoj.com/problems/MINCOUNT/
http://www.spoj.com/problems/SPEED/