I am working on the Betty’s Bakery assignment and in question 6 they ask us to find all recipes with one egg and to use a logical statement to get
False for each value of
eggs. However, in the video tutorial it just finds and prints the recipes that contain one egg and doesn’t use any True/False statement. https://www.youtube.com/watch?time_continue=1&v=bv5x0BrFyMU&feature=emb_title
Am I interpreting the question incorrectly or is the video missing something? Maybe as a non native speaker I am missing something?
I tried to get a list with True or False, but was only able to do it for a single row in my list using a lambda function:
recipes = np.genfromtxt(“recipes.csv”, delimiter = “,”)
eggs = recipes[:,2]
one_egg = lambda eggs: “True” if eggs == 1 else “False”