在Python中,汉字通常使用Unicode字符集进行表示。Python 3中,字符串默认就是Unicode类型,可以直接使用引号包裹汉字文本。如果使用Python 2,需要确保文件编码设置为UTF-8,例如使用` -*- coding: utf-8 -*-`声明文件编码。
```python
-*- coding: utf-8 -*-
chinese_str = "你好,世界!"
print(chinese_str)
在Unicode中,汉字的编码范围通常是从`\u4e00`到`\u9fff`。