Question: In coding example 5 . 2 Order a taco, you were asked to write a program to order a customized taco. Why is this line
In coding example Order a taco, you were asked to write a program to order a customized taco.
Why is this line of code prone to user error?
topping toppingsinttopchoice
A user could enter a float, which lists can't index from.
A user could enter a number that would evaluate to an index that doesn't exist in the list
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
