Loading...
Create functions with default arguments and keyword arguments.
Python functions support:
Write a function **create_profile(name, age=18, city="Unknown", extra) that creates a user profile.
Return a dictionary with all provided information:
create_profile("Alice", age=25, city="NYC", job="Engineer"){'name': 'Alice', 'age': 25, 'city': 'NYC', 'job': 'Engineer'}Named args override defaults, **kwargs captures extra args