📅  最后修改于: 2022-03-11 14:46:54.751000             🧑  作者: Mango
import codecs # Python standard library
codecs.encode("A strange character","utf-8")
# this would give you the utf-8 encoded bytes