学《learn python the hard way》(1)
2013-08-18 15:54
260 查看
做了两课练习:
ex1.py
ex2.py
ex1.py
#print "Hello World!" #print "Hello Again" #print "I like typing this." #print "This is fun." #print 'Yay! Printing.' #print "I'd much rather you 'not'." #print 'I "said" do not touch this.' print 'what the deference?'练习print
ex2.py
# A comment, this is so you can read your program later. # Anything after the # is ignored by python. print "I could have code like this." # and the comment after is ignored # You can also use a comment to "disable" or comment out a piece of code: print "This will run."练习注释#
相关文章推荐
- 【Python】Learn Python the hard way, ex21 函数返回值return
- Learn Python The Hard Way学习(3) - 数字和数学计算
- Learn Python The Hard Way学习(4) - 变量和命名
- Learn Python The Hard Way学习(12) - 输入提示
- Learn Python The Hard Way学习(17) - 更多的文件操作
- Learn Python The Hard Way学习(19) - 函数和变量
- Learn Python the hard way 习题49
- Learn Python The Hard Way学习(47) - 自动化测试
- Learn Python The Hard Way 3: Ex0 Setup
- Learn Python The Hard Way-Ecercise1~5
- Learn Python The Hard Way, 2nd Edition 尾声
- Learn Python The Hard Way-Ecercise6~10
- Learn Python The Hard Way 总结与勘误
- 【Python】Learn Python the hard way, ex4 使用变量
- Learn Python The Hard Way中习题46安装distribute包和virtualenv包
- 【Python】Learn Python the hard way, ex18 def函数
- 【Python】Learn Python the hard way, ex35 通过一个简单游戏,练习循环和分支语句
- Learn Python The Hard Way学习(5) - 更多的变量和打印
- Learn Python The Hard Way学习(13) - 参数,解包,变量
- Learn Python The Hard Way学习(20) - 函数和文件