print ("My name is Vlad!") print ("I'm just starting out with Python programming!!") #print ("These are simple intro comments") a = 5 b = 15 print (a + b) #print ("Introductory variables") a = "8.5" b = 45 print (float(a) + b) print (3**8) #print ("Double * = to the power") b = 51 if b <= 50: print ("less than 50") #print ("Remember the colon") elif b >=35: print ("greater than 35") def testfunction(a=4,b=9,c=14,d=32): return a+b+c+d print(testfunction()) #print ("First function created, remember the brackets") print ("Choose option:") print ("1. Addition") print ("2. Subtraction") print ("3. Multiplication") print ("4. Division") choice=input() if choice==1: numlist=[] print ("You have chosen option 1, Addition MODAFAKA.") elif choice==2: numlist=[] print ("Option 2, Subtraction, has been chosen.")
Run
Reset
Share
Import
Link
Embed
Language▼
English
中文
Python Fiddle
Python Cloud IDE
Follow @python_fiddle
Browser Version Not Supported
Due to Python Fiddle's reliance on advanced JavaScript techniques, older browsers might have problems running it correctly. Please download the latest version of your favourite browser.
Chrome 10+
Firefox 4+
Safari 5+
IE 10+
Let me try anyway!
url:
Go
Python Snippet
Stackoverflow Question