initial implementation for min/max methods