# calculate
print(1-2)
print(4*5)
print(7/5)
print(3**2)

# check type
print(type(10))
print(type(2.78))
print(type("hello"))

# use variable
x = 10
print(x)
x = 100
print(x)
y = 3.14
print(x*y)
print(type(x*y))

# list
a = [1, 2, 3, 4, 5]
print(a)
print(len(a))
print(a[0])
print(a[4])
a[4] = 99
print(a)
print(a[0:2])
print(a[1:])
print(a[:3])
print(a[:-1])
print(a[:-2])

# dictionary
me = {'height': 180}
print(me['height'])
me['weight'] = 70
print(me)

# boolean
hungry = True
sleepy = False
print(type(hungry))
print(not hungry)
print(hungry and sleepy)
print(hungry or sleepy)

# if
if hungry:
    print("I'm hungary")
else:
    print("I'm not hungary")
    print("I'm sleepy")

# for
for i in [1, 2, 3]:
    print(i)
# calculate
print(1-2)
print(4*5)
print(7/5)
print(3**2)

# check type
print(type(10))
print(type(2.78))
print(type("hello"))

# use variable
x = 10
print(x)
x = 100
print(x)
y = 3.14
print(x*y)
print(type(x*y))

# list
a = [1, 2, 3, 4, 5]
print(a)
print(len(a))
print(a[0])
print(a[4])
a[4] = 99
print(a)
print(a[0:2])
print(a[1:])
print(a[:3])
print(a[:-1])
print(a[:-2])

# dictionary
me = {'height': 180}
print(me['height'])
me['weight'] = 70
print(me)

# boolean
hungry = True
sleepy = False
print(type(hungry))
print(not hungry)
print(hungry and sleepy)
print(hungry or sleepy)

# if
if hungry:
    print("I'm hungary")
else:
    print("I'm not hungary")
    print("I'm sleepy")

# for
for i in [1, 2, 3]:
    print(i)

# function
def hello():
    print("Hello World!")

hello()

def hello(object):
    print("Hello " + object + "!")

hello("cat")
Add python function code