我知道我们可以在字符串之前使用r(原始字符串)和u(unicode)标志来获得我们实际需要的内容。但是,我想知道这些如何处理字符串。我在空闲试过这样: a = r"This is raw string and \n will come as is"
print a
# "This is raw string and \n will come as is"
help(r)
# ..... W
请看下面的演示脚本: # -*- coding: utf-8 -*-
from __future__ import division
from __future__ import unicode_literals
def myDivi():
"""
This is a small demo that just returns the output of a diviso