c# - How to check if Strings all characters in a specific unicode range? -
this question has answer here:
hi example have string
in sinhala unicode
string variable = "සහ"; - correct string string variable = "xසහs"; - incorrect string
i want validate if all characters string in specific unicode range belongs specific language.
any idea of achiving ?
static bool validate(string s, char max, char min) { (int = 0; < s.length; i++) if (s[i] > max || s[i] < min) return false; return true; }
Comments
Post a Comment