| Author |
User inputs
|
Jools Birch
Greenhorn
Joined: Nov 01, 2003
Posts: 6
|
|
I'm wondering how you would go about making a program that prints out a users input. Could I have code for it?
|
 |
Ernest Friedman-Hill
author and iconoclast
Marshal
Joined: Jul 08, 2003
Posts: 24056
|
|
But of course, this isn't what you're really after. Want to be more specific?
|
[Jess in Action][AskingGoodQuestions]
|
 |
Jools Birch
Greenhorn
Joined: Nov 01, 2003
Posts: 6
|
|
Like this Prompt user to enter a text "Enter something" Once the user presses Enter, whatever the user has inputted is displayed.
|
 |
Ernest Friedman-Hill
author and iconoclast
Marshal
Joined: Jul 08, 2003
Posts: 24056
|
|
Not to give it all away for free... Prompt by printing to System.out, of course. Read a line by wrapping System.in in an InputStreamReader and a BufferedReader in turn, then calling BufferedReader.readLine(). Then print the result to System.out.
|
 |
Jools Birch
Greenhorn
Joined: Nov 01, 2003
Posts: 6
|
|
|
Why not "give away for free", it's not that much of a program is it?
|
 |
William Barnes
Ranch Hand
Joined: Mar 16, 2001
Posts: 965
|
|
|
Free code
|
Please ignore post, I have no idea what I am talking about.
|
 |
 |
|
|
subject: User inputs
|
|
|