anonymous
  • anonymous
I am having trouble with problem 2 on homework one. I have the code all done, but it doesn't like one of my variables... https://gist.github.com/anonymous/6116595
MIT 6.189 A Gentle Introduction to Programming Using Python (OCW)
  • Stacey Warren - Expert brainly.com
Hey! We 've verified this expert answer for you, click below to unlock the details :)
SOLVED
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.
chestercat
  • chestercat
I got my questions answered at brainly.com in under 10 minutes. Go to brainly.com now for free help!
S.Campbell
  • S.Campbell
You don't say what line you get the error on, but you should check carefully the spelling of the variable name(s). I would guess that Python would give a "name not defined" error on either line 11 or line 16. It doesn't appear that the variable used on those lines will have been assigned a value.
anonymous
  • anonymous
while (remainder > 0.0): -- tt looks like remainder also hasn't been defined before it is used
anonymous
  • anonymous
I was thinking the same as above. We work through the program, get to the while loop, and say ' while remainder...' Well, there is not a remainder object in existence yet, so the programs logic grinds to a halt !

Looking for something else?

Not the answer you are looking for? Search for more explanations.