Question (phrased as a scenario.): Every day, when an employee of Swagger Distri
ID: 667265 • Letter: Q
Question
Question (phrased as a scenario.):
Every day, when an employee of Swagger Distribution signs on to her computer, a pop-up window opens and gives a greeting to the employee. The new owner would like to continue to have the pop-up window but would like to change the greeting. You will open up the current code and identify the key components of the code that need to be changed and make those changes. Submit the modified code and identify the various components of that code.
Screen Shot (of "Code" as stated above.):
Thank you very much for your help with answering this question...I'm completely stumped by it!!!!
Explanation / Answer
import java.util.*;
import java.lang.*;
import java.io.*;
class Swagger
{
public static void main (String[] args) throws java.lang.Exception
{
int day;
int month;
int year;
GregorianCalendar date = New GregorianCalendar();
day = date.get(calendar.DAY_OF_MONTH);
month = date.get(calendar.MONTH);
year = date.get(calendar.YEAR);
System.out.print("current date is "+(month+1)+"/"+day+"/"+year);
}
}