home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / lang / perl / 5800 < prev    next >
Encoding:
Text File  |  1992-09-09  |  1.4 KB  |  39 lines

  1. Newsgroups: comp.lang.perl
  2. Path: sparky!uunet!spsgate!mogate!newsgate!chdasic.sps.mot.com!dichter
  3. From: dichter@chdasic.sps.mot.com (Carl Dichter)
  4. Subject: Re: Prompting for input
  5. Message-ID: <1992Sep9.175931.18694@newsgate.sps.mot.com>
  6. Sender: usenet@newsgate.sps.mot.com
  7. Nntp-Posting-Host: 223.197.55.10
  8. Organization: SPS
  9. References:  <memo.616870@cix.compulink.co.uk>
  10. Date: Wed, 9 Sep 1992 17:59:31 GMT
  11. Lines: 26
  12.  
  13. In article <memo.616870@cix.compulink.co.uk>, pmoore@cix.compulink.co.uk (Paul Moore) writes:
  14. |> 
  15. |> In his posting, James Gillespie says:
  16. |>   > pause.  It appears to me that there must be something left
  17. |>   > on STDIN as a result of entering the string "n\n", but I
  18. |>   > can't find anything in the Camel book about such an
  19. |>   > occurrence, or how to "suck" 
  20. |>  
  21. |> Er - what about the "\n"? getc only gets a single character.
  22. |>  
  23. |> Gustav.
  24. |>  
  25. |> ------------------------------------------------------------------------
  26. |> Paul Moore (pmoore@cix.compulink.co.uk)   |
  27. |> ------------------------------------------------------------------------
  28. |> Programming is the process of debugging an empty source file
  29. |> ------------------------------------------------------------------------ 
  30. |> 
  31.  
  32. That's why Tom says to use <STDIN>.
  33. That way it "eats" the newline too.
  34.  
  35. ----------------------
  36. Carl R. Dichter             "iwannanugui"
  37. Motorola ASIC Division
  38. email: dichter@chdasic.sps.mot.com
  39.