Category "nsnumber"

Convert Integer to Roman Numeral String in Swift

I am looking to take an Integer in Swift and convert it to a Roman Numeral String. Any ideas?

Convert Integer to Roman Numeral String in Swift

I am looking to take an Integer in Swift and convert it to a Roman Numeral String. Any ideas?

Prevent small negative numbers printing as "-0"

If I do the following in Objective-C: NSString *result = [NSString stringWithFormat:@"%1.1f", -0.01]; It will give result @"-0.0" Does anybody know how I ca

iOS convert large numbers to smaller format

How can I convert all numbers that are more than 3 digits down to a 4 digit or less number? This is exactly what I mean: 10345 = 10.3k 10012 = 10k 123546 = 12

iOS convert large numbers to smaller format

How can I convert all numbers that are more than 3 digits down to a 4 digit or less number? This is exactly what I mean: 10345 = 10.3k 10012 = 10k 123546 = 12