A Python Project

Hello ,

I have made a code in python with
if, else, elif conditions, the way the game works is that you are tasked to create a salad and the program will ask you if you which toppings you would like to use eg. “Would you like to add tomatoes to your salad?”: which can be answered with yes/no, I have found that it will take very long to code the full project with this way because it is required to make 2 different stories for each input statement since there are 2 answers for each ( yes or no ) and I just wanted to ask you if there is an easier way to code this program?

Thank you.

1 Like

In Python, using the dict type can simplify conditional branching when there are many options.

1 Like

Thank you.

1 Like