Math.min in objective c
You can use MIN
from NSObjCRuntime.h
:
#ifndef MIN#import <NSObjCRuntime.h>#endifresult = MIN(MIN((hra * 12), rent), (0.4 * pay));
You can use math.h from C :
#import <math.h>// double fmin (double, double)NSLog(@"res: %.f", fmin(5,10));