Complete the code to split a big task into smaller steps using a list.
steps = ["Understand problem", [1], "Test solution"]
We split the big task into smaller parts to handle it easily.
Complete the code to create a function that runs each step in order.
def run_steps(steps): for step in [1]: print(f"Doing: {step}")
We loop through the list of steps to run them one by one.
Fix the error in the code that tries to run steps but uses wrong variable name.
def execute(steps): for s in [1]: print(f"Execute: {s}")
The function parameter is named 'steps', so we must loop over 'steps'.
Fill both blanks to create a dictionary mapping step names to their order number.
step_order = {step: [1] for [2], step in enumerate(steps)}We use 'enumerate' to get index and step, then map step to index.
Fill all three blanks to filter steps that contain the word 'data' and count them.
filtered = [step for step in steps if [1] in [2]] count = len([3])
We check if 'data' is in each step, collect those steps, then count them.
