
python
钱臻fireball
Nothing to say!
展开
-
Python3.5 安装
编译环境准备准备一下编译环境,防止出现安装错误yum groupinstall 'Development Tools' yum install zlib-devel bzip2-devel openssl-devel ncurese-devel下载python3.5代码包这里选择下载最近版本的Python3.5.1 (2016-05) wget https://www.python.org/转载 2017-11-13 14:53:33 · 464 阅读 · 0 评论 -
Python学习笔记
一.格式化字符串1.数字转义成字符串num=18print 'My age is' + num程序就会报错。因为字符和数字不能直接用+相加。#办法一:通过str()num = 18print 'My age is' + str(num)#办法二:num = 18print 'My age is %d'%num #%d只用于整数print ‘Price原创 2018-01-23 11:08:51 · 261 阅读 · 0 评论