cjk

Find all the Korean Carachters in a word in Python

Find all the Korean Carachters in a word in Python Question: I’m trying to get a list of every character of a korean syllable of input, such as: example = ‘만들다’ But when I try it with: print([*example[-2]]) I get [‘들’] While I’m trying to get as output something like: [‘ㄷ’, ‘ㅡ’, ‘ㄹ’] Asked By: …

Total answers: 1

Generating chinese/pinyin names

Faker Python generating chinese/pinyin names Question: I am trying to generate random chinese names using Faker (Python), but it generates the names in chinese characters instead of pinyin. I found this : and it show that it generates them in pinyin, while when I try the same code, it gives me only chinese characters. how …

Total answers: 1

text to csv file for japanese characters(Errors in arrangements)

text to csv file for japanese characters(Errors in arrangements) Question: I wanted to convert my text file into csv file, however, my output seems to be very different from what I expected. Below are the examples: text.txt (Encoding is “UTF-8”) text = -0.00010712468871868001 gram_0:Coll:0::ん -0.00010712468871868001 gram-1:Coll:-1::止まる -0.00010712468871868001 gram-3:Coll:-3::帰る -0.00010712468871868001 gram1:Coll:0::ん -0.00010712468871868001 gram2:Coll:2::いく -0.00010712468871868001 gram3:Coll:3::く My …

Total answers: 1

Encoding mail subject (SMTP) in Python with non-ASCII characters

Encoding mail subject (SMTP) in Python with non-ASCII characters Question: I am using Python module MimeWriter to construct a message and smtplib to send a mail constructed message is: file msg.txt: ———————– Content-Type: multipart/mixed; from: me<[email protected]> to: [email protected] subject: 主題 Content-Type: text/plain;charset=utf-8 主題 I use the code below to send a mail: import smtplib s=smtplib.SMTP(‘smtp.abc.com’) …

Total answers: 3