added min and max to u