摘要: #两个文件要放在同一目录中,包括图片 一、搭建游戏舞台主程序 #!/usr/bin/env python3#_*_coding:utf-8_*_ author ==$ VACyp import sysimport pygamefrom girl import Girl def build_pygwi 阅读全文
posted @ 2019-01-06 21:55 vacpy 阅读(337) 评论(0) 推荐(0) 编辑
摘要: Ubuntu18.04默认内嵌python2、python3,pip安装时,python2对应安装pip,python3对应安装pip3. sudo apt install python3-pip 检查版本: pip3 -V pip 9.0.1 from /usr/lib/python3/dist- 阅读全文
posted @ 2018-12-15 14:26 vacpy 阅读(700) 评论(0) 推荐(0) 编辑
摘要: file_path =(r'i:\vacpy\ch10\pi_digits.txt') #将文件路径存储在变量file_path中with open (file_path) as file_object: contents = file_object.read() print(contents)"" 阅读全文
posted @ 2018-12-09 14:31 vacpy 阅读(1206) 评论(0) 推荐(0) 编辑
摘要: active =Truewhile active: message =input("\nPlease input your name:\n") if message =='q': break print("welcome " + message + " come to our website!") 阅读全文
posted @ 2018-12-08 23:26 vacpy 阅读(36653) 评论(0) 推荐(2) 编辑