By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,176 Members | 984 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,176 IT Pros & Developers. It's quick & easy.

on STDIN

100+
P: 129
Hello friends,
I have a small doubt that when we want to take a value from keyboard we use STDIN in perl. When we use that word the control will waits to take input and after giving the input we have to press enter at the end of input. Then only it consider the input or stores the value in some variable.

But what my context is, after giving input we don't want to press enter i.e after giving the input it do the next action no pressing of enter.
Can anybody solve this problem?
Oct 16 '08 #1
Share this Question
Share on Google+
1 Reply


P: 4
hi there...the reason of pressing "enter-key" is to denote that you are marking the end of your input text stream.(data/keyword.. whatever....)
if you dont press enter, how is perl going to interpret that the data input supplied by you.is of the extent limited by you..
Alternately, you can press EOF ("ctrl-d") twice. it actually means 'end-of-file' but it can be used like that(mentioned above ) to signify end of your input text stream.
Oct 16 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.