<jupyter_start><jupyter_text>Functions_Authors: Mahesh--- Lesson objectivesBy the end of this lesson, you should be able to:1. Successfully **create** and **invoke** a function2. Understand how to use parameters in a function3. Understand how to return a value from a function4. Know what a lambda function is and how to create one Intro---From the pre-work (and perhaps what you've done before DSI), remember that functions:- start with `def`, followed by the name of the function.- take inputs (or arguments).- return outputs.- use `return` instead of `print`.- are used frequently to make coding more efficient.One of my favorite novels - <NAME>'s *Fahrenheit 451* - has a quote that is appropriate here: > "We begin by beginning, I guess."  Activity: Basic function---Create a function in cell below called `greeting` that prints `"Howdy"`.<jupyter_code># Declare the function
# Invoke the function<jupyter_output><empty_output><jupyter_text>Activity: Function parameters---In the [Kaggle Titanic competition](https://www.kaggle.com/c/titanic/data), the names of everyone in the manifest look like this:> Last, Title. FirstCreate a function called `titanic_name` that accepts 3 parameters:- `first_name`- `last_name`- `title` And prints the full name in the format above.  Named parameters vs Ordered parameters---In the above example, you must order in which you add your arguments coincides with the order of the parameters in the function declaration. If you called them out of order like so:```pythontitanic_name('Doe', 'Captain', 'John')```Then the following would happen:1. `'Doe'` would be assigned to `first_name`2. `'Captain'` would be assigned to `last_name`3. `'John'` would be assigned to `title`.As a result, the function would print `'Captain, <NAME>'`. No bueno.<jupyter_code># greet_by_name
# titanic_name<jupyter_output><empty_output>