##############
####python####
##############
yum install python
python
>>> print "hello zzf"
hello zzf
>>> westos = "welcome to westos"
>>> print westos
welcome to westos
>>> exit
exit() or Ctrl-D
>>> print "我爱你中国"
我爱你中国
[root@server python]# vim python.py
westos = "welcome to westos"
print westos
[root@server python]# chmod +x python.py
[root@server python]# ./python.py
welcome to westos
[root@server python]# vim python.py
#coding:utf-8
[root@server python]# ./python.py
welcome to westos
我爱你中国
#编码格式
ASCII:1字节=8bit(8个0101字符) 最多存储2^8-1=255
Unicode:2字节=16bit, 最多存储2^16-1=65535 一个汉字2个字节
utf-8:英文一个字节存储,其他三个字节存储
GB2312:
#python解释器
CPython:是用c写的python解释器
Ipython:在cpython基础上的加强型交互式python解释器
Pypy:用python开发的python解释器
Jpython:用java开发的python解释器
IronPython:
#python编辑工具:
cd python/
ls
cd pycharm/
ls
tar xf pycharm-community-2017.1.4.tar.gz -C /opt/
cd /opt/
ls
cd pycharm-community-2017.1.4/
ls
cd bin/
ls
./pycharm.sh 进入到编辑界面
默认选择第二个
接受协议
选择enable……
共享按键钩上 ok
创建新的工程
alt+F12 打开terminal
alt+4运行命令
#数值类型
整形aInt 1