In one of the sample codes by Apple, I see the following lines:
int digits = MAX( 0, 2 + floor( log10( newDurationSeconds)));
self.exposureDurationValueLabel.text = [NSString stringWithFormat:@"1/%.*f", digits, 1/newDurationSeconds];
I am not able to understand the syntax, there are two arguments to stringWithFormat: but only one % sign. I understand it is string value of 1/newDurationSeconds upto N=digits but the syntax is something I don't get.
And how do I translate it to Swift 3?