min amd max added