Added a special case for min and max.