I am trying to determine if a string is Latin or Japanese.
I tried something like the following, but it returns YES for Japanese strings:
NSCharacterSet *alphaSet = [NSCharacterSet alphanumericCharacterSet]; BOOL isAlpha = [[myStr stringByTrimmingCharactersInSet:alphaSet] isEqualToString:@""];
The string may be the word "cafe" or something like "γ« γ γ§" or "ε«θΆ εΊ".
objective-c iphone cocoa-touch
Louis Mar 24 2018-11-11T00: 00Z
source share