Commit f1e614bb by BellCodeEditor

auto save

parent 42f5e958
Showing with 73 additions and 0 deletions
"""
print("我是输出")
input("我是输入")
#input_food下划线命名
#InputFood驼峰命名
counter = 100 #整数
miles = 100.0 #浮点数
name = "bellcode" #字符串
print(type(counter))
print(type(miles))
print(type(name))
#连续赋值相同的值
a = b = c = 1
print(a,b,c)
a,b,c = 1,2,3
print(a)
print(b)
print(c)
x = 21
y = 8
print("x+y=",x+y)
print("x-y=",x-y)
print("x*y=",x*y)
print("x/y=",x/y)
print("x//y=",x//y)#取整
print("x%y=",x%y)#取余
print("x**y=",x**y)#幂次方
a = 0
a += 1 #等于a = a +1
width = int(input("三角形底"))
height = int(input("三角形高"))
print(type(width))
print(type(height))
#"打印三角形面积"
print("三角形面积是:",width*height/2)
"""
# x = "2"
# x = "2.4" #向下取整 一步一步操作
# print(type(int(x)))
# x = 2
# z = complex(x)
# print(z)
# x = 21
# print("第一次结果",type(x))
# x = float(x)
# print("第二次结果",type(x))
# x = 21
# y = 8
# z = complex(x,y)
# print(z)
# print(type(z))
str1 = 'hahahah'
str2 = "hahahah"
str3 = """hahahha"""
print(str1,str2,str3)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment