When you run a Java program called Foo, anything typed on the command lineafter "java Foo" is passed to the main method in the args parameter as an array of strings.
1. Write a program Average.java that just prints the strings that it is given at the command line, one per line. If nothingis given at the command line, print "No arguments".
2. Modify your program so that it assumes the arguments given at the command line are integers. If there are noarguments, print a message. If there is at least one argument, compute and print the average of the arguments. Notethat you will need to use the parseInt method of the Integer class to extract integer values from the strings that arepassed in. If any non-integer values are passed in, your program will produce an error, which is unavoidable at thispoint.