Skip to content

Instantly share code, notes, and snippets.

@samwho
Created April 6, 2011 10:53
Show Gist options
  • Save samwho/905466 to your computer and use it in GitHub Desktop.
Save samwho/905466 to your computer and use it in GitHub Desktop.
Some basic arithmetic in Python.
2 + 2 # addition, returns 4
4 - 1 # subtraction, returns 3
5 * 5 # multiplication, returns 25
2 ** 3 # 2 to the power of 3, returns 8
10 / 2 # division, returns 5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment