python基础——第一天(初识python和第一个python程序)

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/ZENGZISUZI/article/details/81023907
  • 特点
    优雅
    明确
    简单
  • 适合领域
    Web网站和各种网络服务
    系统工具和脚本
    作为“胶水”语言把其他语言开发的模块包装起来,方便大家使用
  • 不适合
    贴近硬件(c)
    移动开发(ObjC/Swift/Java)
    游戏开发(c/c++)
  • 开发环境安装
    https://www.python.org/getit/
    很慢。。。。。。(百度网盘私信)
    安装务必将Add Python xxx to PATH(这样就不用手动配置环境变量啦)
    安装好后cmd可以查看版本
    这里写图片描述
  • 解释器
    python代码以.py结尾,运行代码需要解释器去执行.py文件
    Python的解释器很多,但使用最广泛的还是CPython
    pthon 3.x版本下运行。请务必在本地安装CPython
  • 输出/输出
print()
input()

可以用逗号表示空格

  • 例子
print('hello','world','by','youyi')
print('input')
print('hello world')
print('hello','world','by','youyi')
print(250)
print(250+250)
print('250+250=',250+250)
print('output')
name = input('Please enter your name: ')
print('your name is ',name,'Hello ',name)
  • 运行效果
    这里写图片描述

猜你喜欢

转载自blog.csdn.net/ZENGZISUZI/article/details/81023907