Possible Duplicate:
How to add percent sign to NSString
I am trying to print red (10.0 %)
in Objective-C using the statement:
$ newlabel1.text= [[NSString alloc] initWithFormat:@"red (%.1f %)",rv];
However, I am getting red(10.0)
only, and the %
symbol was not printing. How can I make the percentage symbol print?
You should double the percent sign (%%).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With