Assignment: #MakeHelloWorld Due: 01/22/2017 Points: 3

Specification

Create a public class MakeHelloWorld that when executed prints the code for a public class HelloWorld to the standard output stream. The generated public class HelloWorld, when compiled and executed, prints the phrase hello, world followed by a newline to the standard output stream.

Example using the command-line.

   prompt:  edit MakeHelloWorld.java 
   prompt:  javac MakeHelloWorld.java
   prompt:  java MakeHelloWorld >HelloWorld.java   
   prompt:  javac HelloWorld.java
   prompt:  java HelloWorld
   hello, world

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 
   a newline to the standard output stream. This program was program 
   generated.

   @creator YOUR_FULL_NAME_GOES_HERE
   @generated YYYYY.MM.DD_FORMATTED_DATE_GOES_HERE

The output for Edith Foogooman's program looks like the following.

   /*
    * This Java application prints the phrase hello, world followed by 
    * a newline to the standard output stream. This program was program 
    * generated.
    *
    * @creator Edith Foogooman
    * @generated 02017.01.17
    */

   public class HelloWorld 
   {
      public static void main(String[] argv) 
      {
         System.out.print("hello, world\n");     
      }
   }
Important Notes
  1. The YYYYY.MM.DD formatted date in the generated public class HelloWorld must 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 class Calendar}

  2. The generated public class HelloWorld must use System.out.print() and not System.out.println() when printing the phrase hello, world to the standard output stream.