1.pycharm
①IDE:
Integrated Development Environment(集成开发环境)
②python的IDE:
VIM:Linux下的经典的文本编辑器之一
Emacs:Linux下的经典的文本编辑器之一
Eclipse:Java IDE、支持Python、C、C++等
Visual Studio:微软开发的IDE、python、c++、java、C++等
Notepad++
Sublime Text:python开发的
Pycharm:是主要用于python开发的IDE
安装Pycharm
2.字符格式化输出

微信截图_20171130184759.png
占位符:%s s=string
%d d=digit 整数
%f f=float 浮点数
3.数据类型初识
数字
整数: int (integer)
整型 type: int
长整型 type: long
in python3 已经不区分整型和长整型了,统一叫整型
浮点型: float
复数: complex
布尔值
计算机中最基本的数据类型,只有两种状态:
True 真
False 假
字符串
salary.isdigit()
计算机中,一切皆为对象
世界万物,皆为对象,一切对象皆可分类
字符串拼接:
注意:不要用“+”拼接字符串,因为每多一个“+”就会多开发出一个内存,运行速度会下降
4.for
循环(loop):
有限循环,有次数限制

image.png

image.png

image.png

image.png
无限循环=死循环

image.png
5.while

image.png
6.break

image.png

image.png
跳出当前整个循环
7.continue

image.png
结束本次循环,继续下次循环
8.数据类型
列表
元组