Dec-29-2019, 06:00 PM
You are using py as an argument to yeild_perc on line 12. But py is defined inside the yield_perc function. You can't access values within a function without returning them, and certainly not before/as the function is actually called.
I would just remove that arguments/parameter from the yeild_perc function, since it is defined in the function with an input statement. But you will have other problems, because input returns a string. You need to convert those values to numbers with float() or int() before you do math on them.
I would just remove that arguments/parameter from the yeild_perc function, since it is defined in the function with an input statement. But you will have other problems, because input returns a string. You need to convert those values to numbers with float() or int() before you do math on them.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures