Python字符串转换 str与int互转

字符串str转换成int: int_value = int(str_value)

int转换成字符串str: str_value = str(int_value)

int -> unicode: unicode(int_value)

unicode -> int: int(unicode_value)

str -> unicode: unicode(str_value)

unicode -> str: str(unicode_value)

int -> str: str(int_value)

str -> int: int(str_value)

你可能感兴趣的:(Python,python,字符串转换)