## TYPE THIS IN THE CONSOLE - CHECK THE TYPE OF OBJECTS ##
type(5)
type(3.0)

## TYPE THIS IN THE CONSOLE - CONVERT TO ANOTHER TYPE ##
float(3)
int(3.9)
round(3.9)

## TYPE THIS IN THE CONSOLE - EXPRESSIONS ##
3+2
(4+2)*6-1
type((4+2)*6-1)
float((4+2)*6-1)

## TYPE THIS IN THE CONSOLE - VARIABLES ##
pi = 355/113

#Compute approximate value for pi
pi = 355/113
radius = 2.2
area = pi*(radius**2)
circumference = pi*(radius*2)

## CODE STYLE ##

# Example 1
#do calculations
a = 355/113 *(2.2**2)
c = 355/113 *(2.2*2)

# Example 2
p = 355/113
r = 2.2
#multiply p with r squared
a = p*(r**2)
#multiply p with r times 2
c = p*(r*2)

#Example 3
#calculate area and circumference of a circle using an approximation for pi
pi = 355/113
radius = 2.2
area = pi*(radius**2)
circumference = pi*(radius*2)

## CHANGING BINDINGS ##
pi = 3.14
radius = 2.2
area = pi*(radius**2)
radius = radius+1


## DEBUG THIS - SWAP VALUES ##
# Given x and y below, the code incorrectly swaps the values. Fix it!
x = 1			
y = 2
#Buggy example
y = x
x = y
#Fix it here!



###############################
###### COMMENTING LINES #######
###############################
## to comment MANY lines at a time, highlight all of them then CTRL+1
## do CTRL+1 again to uncomment them
## try it on the next few lines below!

# pi = 355/113
# radius = 2.2
# area = pi*(radius**2)
# circumference = pi*(radius*2)

###############################
###### AUTOCOMPLETE #######
###############################
## Spyder can autocomplete names for you (in console or the editor)
## start typing a variable name defined in your program and hit tab 
## before you finish typing -- try it below

## define a variable
#a_very_long_variable_name_dont_name_them_this_long_pls = 0

## start typing a_ve then hit tab... cool, right!
## use autocomplete to change the value of that variable to 1

## use autocomplete to show the type of the value of that long variable
## notice that Spyder also automatically adds the closed parentheses for you!
