unicode - Objective-C and scanning an integer or character to a hex representation -


nsscanner has instance method -scanhexint: converting hexadecimal string representation of int int. i'd invert this: i'd method takes int , returns hexadecimal representation.

is there ready made method in docs?

[to more relevant, i'd take string comprising single kanji , return unicode point.]

if check documentation on string format specifiers, you'll see there several specifiers can use hexadecimal string representation of number. instance, use:

[nsstring stringwithformat:@"%x", foo] 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -