public class DemoInput
{
   public static void main(String args[]) throws Exception
     {
     char userInput;
     System.out.println("please enter a character ");
     userInput = (char)System.in.read();
     
     // This method gets the input from the keyboard.
     /* The read() method accepts a byte and returns an integer.
      * It does not make sense that this method returns an integer value but
      * to the computer, all values are integers because computers store input as a series
      * of 0s and 1s. And this return the value -1 when the compiler reaches the end of a file
      */
     // The cast (char) converts the returned integer into a character


     System.out.println("You entered "  + userInput);

    }
   }
