James Edward Gray II wrote: > > I have a question about this solution. You're stopping when you see a > carriage-return above, but what does Windows really tact onto the end > of the line? Nothing, by using getch I get every character and DOS/Windows doesn't do anything. That is why I put that extra puts there. Otherwise the result looks like this: Please give me your password: Got 'ryan' > Is it a carriage return line feed pair, as I suspect? Nope. > Put another way, if you changed the above from 13 to 10, would it still > work? Nope. In that case you have to type Ctrl-J to end, whereas with 13 you can hit the enter key or type Ctrl-M. I'm starting to think you will see the same behavior on Unix and Mac. > Last question on this, I promise. Does Windows echo the carriage > return (and possibly line feed), when character reading like this? As I said above, it echoes nothing. I'm definitely thinking my solution would make a good general multi-platform password prompter, with only the implementation of getch requiring multi-platform code. Ryan