SHARE
TWEET

Untitled

a guest Jul 16th, 2019 69 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. chi_char = open(chinese_file,'r',encoding='UTF-8').read()
  2. include = set(string.printable+all_chi_char)
  3.  
  4. full_text = open(source_file,'r',encoding='UTF-8').read()
  5. output_text = ''.join(ch for ch in full_text if ch in include)
  6.      
  7. chi_char = open(chinese_file,'r',encoding='UTF-8').read()
  8. include = set(string.printable+all_chi_char)
  9.  
  10. full_text = open(source_file,'r',encoding='UTF-8').read()
  11. output_text = ''
  12. for ch in full_text:
  13.     if ch in include:
  14.         output_text += ch
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top