Guest User

Untitled

a guest
Apr 24th, 2018
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.21 KB | None | 0 0
  1. import unicodedata
  2.  
  3. texto_1 = 'Ni\u00f1o'
  4. texto_2 = 'Nin\u0303o'
  5.  
  6. print(texto_1 == texto_2)
  7.  
  8. texto_1 = unicodedata.normalize('NFC', texto_1)
  9. texto_2 = unicodedata.normalize('NFC', texto_2)
  10.  
  11. print(texto_1 == texto_2)
Add Comment
Please, Sign In to add comment