Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: select?

by chipmunk (Parson)
on Dec 27, 2000 at 23:05 UTC ( [id://48501]=note: print w/replies, xml ) Need Help??


in reply to select?

Well, I have to ask, why don't you want to use a module?

Here are some selections from perlfaq which you may find useful:
How can I read a single character from a file? From the keyboard?
How can I tell if there's a character waiting on a filehandle?
How do I read just one key without waiting for a return key?
How do I check whether input is ready on the keyboard?
(I found these with `perldoc -q` and then found the corresponding nodes on this site so I could link to them.)

Replies are listed 'Best First'.
Re: Re: select?
by BooK (Curate) on Dec 27, 2000 at 23:11 UTC

    The O word...

    I thought select would be a good choice, since I can set a timeout. But, when I use it with STDIN, I always get a "Bad filehandle" error (in $!). That's why I asked for help specifically about select... (I knew I shouldn't have mentionned the user behind the keyboard)

      That is the first truly great reason I have heard for insisting that a solution not use modules. One more absolute that now has to be moderated with an except... =)

      In the future, you should mention that up front when you insist on core features only, that way if someone is really ornery, they might just find a vile way to load the module they want as a bonus...

      --
      $you = new YOU;
      honk() if $you->love(perl)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://48501]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (4)
As of 2025-07-15 16:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.