title: Java year display coming out in 3 digits
body: <p>I'm trying to do a simple console display in Eclipse and my time and date are coming directly from the computer.  For some reason, the year display is only coming out in 3 characters instead of 4, and I have no idea why.  Any help would be amazing.  Here's the code:</p>
  
  <pre><code>public class InClass3 implements ActionListener
  {
  static int month, day, year, hour, minute;
  
  public static void Display()
  {
      int i;
      String []Date = new String[3];
      String []Hello = new String[3];
      String []Time = new String[3];
      Date();
      Time();
      for (i = 0; i &lt; 3; i ++)
      {
          switch (i)
          {
          case 0:
              Hello[0] = "HELLO WORLD";
              Date[0] = month + "/" + day + "/" + year;               
              Time[0] = hour + ":" + minute;
              break;
  
          case 1:
              Hello[1] = "hello world";
              Date[1] = year + "." + month + "." + day;
              if (hour &gt; 12)
              {
                  hour = hour - 12;
                  Time[1] = hour + ":" + minute + "pm";
              }
              else 
              {
                  Time[1] = hour + ":" + minute + "am";
              }
              break;
  
          case 2:
              Hello[2] = "Hello World";
              Date[2] =  day + " " + month + " " + year;
              Time[2] =  hour + ":" + minute;
              break;
  
          default: System.out.println("Fatal error occured.  Please relaunch this application.");
          }
          System.out.println(Hello[i] + "\n" + Date[i] + "\n" + Time[i]);
      }
  
  }
  
  @SuppressWarnings("deprecation")
  public static void Time()
  {
      Date t = new Date();
      hour = t.getHours();
      minute = t.getMinutes();        
  }
  
  @SuppressWarnings("deprecation")
  public static void Date()
  {
      Date d = new Date();
      year = d.getYear();
      month = d.getMonth();
      day = d.getDay();
  }
  
  public static void main(String[] args) 
  {
      Display();
  }
  
  @Override
  public void actionPerformed(ActionEvent arg0) 
  {
      // TODO Auto-generated method stub
  
  }
  </code></pre>
  
  <p>}</p>
  
  <p>And this is what it's outputting:</p>
  
  <p>HELLO WORLD</p>
  
  <p>3/5/115</p>
  
  <p>14:47</p>
  
  <p>hello world</p>
  
  <p>115.3.5</p>
  
  <p>2:47pm</p>
  
  <p>Hello World</p>
  
  <p>5 3 115</p>
  
  <p>2:47</p>
  
  <p>I would obviously like it to display the 2015 - not the 115.  Thanks for any insight.</p>