All Questions
1 question
5
votes
3
answers
12k
views
Changing large number of if-elif-else statements to use underlying structure
I have a function that looks something like this:
function_name(step, ... , typ):
if typ == 'some type of calc method':
if step == 1:
do_me_at_step_1(...)
elif step ...