How to check if string is 100% ascii in python 3
问题 i have two strings eng = "Clash of Clans – Android Apps on Google Play" rus = "Castle Clash: Новая Эра - Android Apps on Google Play" and now i want to check whether string is in English or not by using Python 3 . I have read this Stackoverflow answer here and it does not help me as its for Python 2.x solution but in comments some one mention that use string.encode('ascii') to make it work in Python 3.x but my problem is, in both cases it raises same UnicodeEncodeError exception! Screenshot: