String Formatting In Objective-C Nicholas Wong 11 Sep 2010 To do formatting in objective-c, the result is 120.54. NSLog([NSString stringWithFormat:@"%.2f", 123*0.98]); It is nearly equivalent to the code in c: printf("%.2f", 123*0.98); Reference Unsorted Nicholas Wong Fullstack software engineer with strong background in computer science and extensive experience in software engineering and architecture. Studied in NYU, worked in Yahoo, Rakuten and Manulife. Nicholas Workshop Newsletter Join the newsletter to receive the latest updates in your inbox. Your email address Subscribe Please check your inbox and click the link to confirm your subscription. Please enter a valid email address! An error occurred, please try again later.