# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     name: python3
# ---

# ## RETURN

def sum(num1, num2):
    num1 + num2



sum(4,5)

print(sum(4,5))


def sum(num1, num2):
    return num1 + num2


print(sum(4,5))

# A function should do one thing really well
# A function should return something
total = sum(10, 5)
print(sum(4, total))


# +
def sum(num1, num2):
    def another_func(num1, num2):
        return num1 + num2

    
# -

total = sum(10, 20)
print(total)


def sum(num1, num2):
    def another_func(num1, num2):
        return num1 + num2
    return another_func


total = sum(10, 20)
print(total)

total = sum(10, 20)
print(total(10,20))


def sum(num1, num2):
    def another_func(num1, num2):
        return num1 + num2
    return another_func (num1, num2)


total = sum(10, 20)
print(total)


def sum(num1, num2):
    def another_func(n1, n2):
        return n1 + n2
    return another_func (num1, num2)


total = sum(10, 20)
print(total)


def sum(num1, num2):
    def another_func(n1, n2):
        return n1 + n2
    return another_func (num1, num2)
    return 5 
    print('helloooooo')


total = sum(10, 20)
print(total)



StarcoderdataJupyterScriptsDedupFiltered