import java.io.*;

/**
 * A simple exho application that demonstrates character-based I/O in Java.
 *
 * @author  Prof. David Bernstein, James Madison University
 * @version 1.0
 */
public class WriterReaderExample
{
    /**
     * The entry point of the application
     *
     * @param args   The command-line arguments
     */
    public static void main(String[] args) throws IOException
    {
	BufferedReader  in;
	PrintWriter     out;
	String          s;


	in = new BufferedReader(new InputStreamReader(System.in));
	out = new PrintWriter(System.out);

	out.print("Enter a word: ");
	out.flush();

	s = in.readLine();

	out.print("\nYou typed: " + s + "\n");
	out.flush();
    }
}
