字符串类型(str)

字符串是字符的序列,基本上就是一组单词,是Python中最常用的数据类型,常用单引号('')或双引号("")创建字符串,也可以使用三引号(''''''或"""""") 示例 str1 = "ali001" str2 = 'ali002' str3 = """Hello""" str4 = '''My name is ali.''' print("str1 is: %s" % str1) prin
相关文章
相关标签/搜索