Da float a int in OBJC

float variabile = 3.1415926535897932384626433;
int intero = (int)variabile;


From string to int in OBJC

As often I risk making fools of conversions into problems, I will post a bit of code that I have used during programming for iOS! You never know that you also run into this problem in the future.

NSString * stringa = @"1";
int intero = [stringa intValue];