Re: [Tutor] When I run this code, it just keeps repeating.

2005-08-01 Thread Bob Gailer
At 06:55 PM 7/30/2005, Nathan Pinno wrote: ...     elif cal_opt == 4:     X = input("First number:" )     Y = input("Second number:" )     if Y == 0:     print "Division by zero ot allowed!"     Y = input("Second number:" )     else:     print X, "/", Y, "=

Re: [Tutor] When I run this code, it just keeps repeating.

2005-07-30 Thread Nathan Pinno
Thanks Todd. Can you please look at my other messages that you haven't answered, and see what's wrong with them, or what the answer is. - Original Message - From: <[EMAIL PROTECTED]> To: Sent: Saturday, July 30, 2005 8:10 PM Subject: Re: [Tutor] When I run this cod

Re: [Tutor] When I run this code, it just keeps repeating.

2005-07-30 Thread python-tutor
Looks like you are making some pretty good progress. The short answer to your question is that the menu & user input need to be inside the while loop. That way cal_opt has a chance to change value before it gets evaluated by the while loop again. Another comment - the global cal_opt is conside

[Tutor] When I run this code, it just keeps repeating.

2005-07-30 Thread Nathan Pinno
When I run the following code it just keeps repeating. Here is a screen shot showing what I mean: Mini CalculatorBy Nathan Pinno   CALCULATE MENU1) Add2) Subraction3) Multiplication4) Division w/o remainder5) Division with remaider6) Exponation7) Square roots9) ExitOption: 5First number:4Seco