The Term::ReadLine package is one option.. You might also try the native
perl function getc.

Bruce W. Lowther
[EMAIL PROTECTED]
Micron Technology, Inc.
Boise, Idaho

-----Original Message-----
From: Goodman Kristi - kgoodm [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 23, 2001 1:05 PM
To: '[EMAIL PROTECTED]'
Subject: Rookie Question



I have this line of code in my program:

print "Did everything look ok? (Y/N)";
chomp ($check = <STDIN>);
$check = "\U$check";
if ("\U$check" ne "Y") {die "Well. . . go back and try again until you get
it right!!!\n"};

How would I fix it where the user did not have to ENTER after they typed a Y
or N.

Thanks for your help!

Reply via email to