Assignment: #MakeHelloWorld Due: 01/27/02019 Points: 3

Specification

Write (i.e. implement/define/code) a public class MakeHelloWorld that when compiled and executed prints the code for a public class HelloWorld to the standard output stream. The generated public class HelloWorld, when compiled and executed, prints to the standard output stream: "hello, world" from YOUR_FULL_NAME followed by a newline.

Example using the command-line for CSC205AA student Dusty Rhodes.

   command-prompt:  edit MakeHelloWorld.java 
   command-prompt:  javac MakeHelloWorld.java
   command-prompt:  java MakeHelloWorld >HelloWorld.java   
   command-prompt:  javac HelloWorld.java
   command-prompt:  java HelloWorld
   "hello, world" from Dusty Rhodes

The generated public class HelloWorld file must contain a file comment block that contains the following.

   This Java application prints the phrase "hello, world"
   followed by programmer name followed by a newline to 
   the standard output stream.

   @creator YOUR_FULL_NAME_GOES_HERE
   @generated YYYYY.MM.DD_FORMATTED_DATE_GOES_HERE
Important Notes
  1. The YYYYY.MM.DD formatted date in the generated public class HelloWorld can be initialized using java.util.Calendar. The year and single digit months & days must be prefixed with a zero. {Cal.java demonstrates the use of Java's class Calendar}

  2. The generated public class HelloWorld cannot use System.out.println() when printing to the standard output stream.

  3. The phrase "hello, world" must be in double quotes and the letters must be lowercase.

Example Output

Edith Foogooman is a CSC205AA student. Edith's program was executed on 27 January 2019 and her program's output looked like the following.

   /*
    * This Java application prints the phrase "hello, world"
    * followed by programmer name followed by a newline to 
    * the standard output stream.
    *
    * @creator Edith Foogooman
    * @generated 02019.01.27
    */

   public class HelloWorld 
   {
      public static void main(String[] argv) 
      {
         System.out.println("Edith says hello...");
      }
   }

Edith's file comment block was correct, but her generated public class HelloWorld did not print the correct output when it was compiled and executed. In addition, Edith called System.out.println() to print to the standard output stream.

   Edith's output:  Edith says hello...
        should be:  "hello, world" from Edith Foogooman