漂亮蓝影 发表于 2017-4-26 08:58:04

python基础1

  1. 2**3 == pow(2,3) == 8
  2. 1/2=0 1.0/2=0.5
  3. import math
  foo = math.sqar
  foo(100)=10.0 --- 神奇
  4 cmath 可以计算 cmath.sqrt(-1) =1j
  5. raw_input input 前者在输入字符串时不需要输入引号 返回类型为字符串,后者需要
  6, print r' /n' 可以输出/n 原始字符串 或者可以使用三个单引号实现''' '''
页: [1]
查看完整版本: python基础1