Skip to content

Instantly share code, notes, and snippets.

@JackZeng
Created April 20, 2012 09:25
Show Gist options
  • Save JackZeng/2427318 to your computer and use it in GitHub Desktop.
Save JackZeng/2427318 to your computer and use it in GitHub Desktop.
test
#coding=utf-8
cars=100 #汽车有100辆
space_in_a_car=4.0 #一辆车内的空间是4平方米
drivers=30 #司机有30个
passengers=90 #乘客有90个
cars_not_driven=cars-drivers #未驾驶的汽车数等于 汽车总数减去司机总数
cars_driven=drivers #被驾驶的车辆数等于司机总数
car_pool_capacity=cars_driven*space_in_a_car #汽车的总载客容量等于被驾驶的汽车乘以每辆车的面积
average_passengers_per_car=passengers/cars_driven #每辆车乘客平均数等于乘客总数除以被驾驶的汽车数量
print "there are", cars, "cars availabe"
print ""
print "下面是更多的打印和变量赋值练习"
def abb(a,b):
c = a + b
return c
pass
print abb(2,8)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment