gs gs128 Java Classes Methods - Java Command Line Arguments - Quiz No.1

gs gs128 Java Quiz

Online Quizzes Preparation

This quiz belongs to book/course code gs gs128 Java of gs organization. We have 136 quizzes available related to the book/course Java. This quiz has a total of 20 multiple choice questions (MCQs) to prepare and belongs to topic Java Classes Methods. NVAEducation wants its users to help them learn in an easy way. For that purpose, you are free to prepare online MCQs and quizzes.

NVAEducation also facilitates users to contribute in online competitions with other students to make a challenging situation to learn in a creative way. You can create one to one, and group competition on an topic of a book/course code. Also on NVAEducation you can get certifications by passing the online quiz test.

Question 1: Which of this method is given parameter via command line arguments?
Question 3: How many arguments can be passed to main()?
Question 4: Which of these is a correct statement about args in the following line of code?

 public static void main(String args[])
Question 5: Can command line arguments be converted into int automatically if required?
Question 12: What will be the output of the following Java snippet, if attempted to compile and execute?

 class abc { public static void main(String args[]) { if(args.length>0) System.out.println(args.length); } } 
Question 14: What will be the output of the following Java code snippet running with "java demo I write java code"?

 public class demo { public static void main(String args[]) { System.out.println(args[0]+""+args[args.length-1]); } } 
Question 16: How do we pass command line argument in Eclipse?
Question 20: What is the use of @syntax?


Online Quizzes of gs128 Java

Other LANG related online quizzes

Other categories of gs Online Quizzes

Other organizations

Theme Customizer

Gaussian Texture



Gradient Background