Code using Java There's a new superhero in town named Environment Woman. She's just mastered her powers and determined her purpose, and now she's ready to head out into the world and start saving the environment! Through numerous shadowy intermediaries, you have been hired as Environment Woman's lead software developer. Congratulations! For your first assignment, you are to write a program that announces Environment Woman to the world. Announce Environment Woman with the following text printed to the command line: Environment Woman is new on the scene! On a separate line, print out Environment Woman's vision: Her goal is to defeat super villains and to save the environment On another line, print out information about you in the following format: First Name Last Name will be assisting Environment Woman as her lead software developer (replace First Name with your first name and Last Name with your last name)
class SuperHero
{
public static void main(String args[])
{
for(int i=0;i<args.length;i++) //loop is used to print command
line arguments
{ // args.length represents length of the arguments
System.out.print(args[i]+" "); // printing arguments
}
System.out.println("\nHer goal is to defeat super villains and to
save the environment!");
System.out.println("James Gosling will be assisting Environment
Woman as her lead software developer!");
}
}
output:
Get Answers For Free
Most questions answered within 1 hours.