Recently I’ve started to learn python, I don’t have any background and I am totally new to it.
The first lessons very pretty easy to pick up, but with the number rising, I find the course to be quite complicated to pick up. At some point, I saw a function with called customer_greetcustomer_customer can I have the smallest idea, why would they have to make it this complicated, when they could easily and simply call it greetcustomer.
Anyways, I am stuck here: https://www.codecademy.com/courses/learn-python-3/lessons/intro-to-functions/exercises/returns
def calculate_age(current_year, birth_year): age = current_year - birth_year
I kinda get it, but I have no freaking idea what it is asking me to do with:
The function **calculate_age** in **script.py** creates a variable called **age** that is the difference between the current year, and a birth year, both of which are inputs of the function. Add a line to return **age**.
What exactly it is asking me to do when saying Add a line to return age. Why cant they write it in a more simpler way to pick it up.
I would appreciate if someone, could explain what exactly are they saying with that, in a simpler way?