mathsoftware

A course about LaTeX and SageMath
git clone https://git.tronto.net/mathsoftware
Download | Log | Files | Refs | README | LICENSE

live1.py (372B)


      1 print(2+2)
      2 
      3 x = input("Input something: ")
      4 print("Your input was:", x, "of type", type(x))
      5 
      6 x_number = int(x)
      7 print("Converted to a number:", x_number, "of type", type(x_number))
      8 
      9 if x_number > 10:
     10 	print("Your number was large!")
     11 	print("It was larger than 10")
     12 	z = x_number-10
     13 	print("This is a smaller number:", z)
     14 else:
     15 	print("Your number was small")
     16 	
     17 print("Bye")