[Python-bugs-list] input() in IDLE (PR#344)

pai@tiac.net pai@tiac.net
Fri, 2 Jun 2000 14:19:59 -0400 (EDT)

Full_Name: Lloyd R. Prentice
Version: 1.5.2
Submission from: ip8.bedford3.ma.pub-ip.psi.net (

I entered and saved an area calculation problem presented in one
of the tutorials. When I run it, it gets to the input statement, then
gets stuck -- it accepts the input, but gives me a new line and continues
to look for input when press the return key.

Here's the program:

# Area Calculation Program

print "Welcome to the Area Calculation Program"
print "_______________________________________"

# Print out the menu:
print "Please select a shape:"
print "1 Rectangle"
print "2 Circle"

# Get the user's choice:
shape = input ("> ")

# Calculate the area:
if shape == 1:
 height = input("Please enter the height: ")
 width = input("Please enter the width: ")
 area = height * width
 print "The area is",area

 radius = input("Please enter the radius: ")
 area = 3.14*(radius**2)
 print "The area is",area

print "done"