首页 > 代码库 > Exercise 6: Strings And Text

Exercise 6: Strings And Text

x = "There are %d types of people." % 10binary = "binary"do_not = "don‘t"y = "Those who know %s and those who %s." % (binary, do_not)print x
print yprint "I said: %r." % x
print "I also said: ‘%s‘." % yhilarious = Falsejoke_evaluation = "Isn‘t that joke so funny?! %r"print joke_evaluation % hilariousw = "This is the left side of..."e = "a string with a right side."print w + e

 

Exercise 6: Strings And Text