Can we use a switch statement with strings?


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More Core Java Interview Questions

What are different types of access modifiers?

3 Answers  


Is main a function?

0 Answers  


Is it possible to write JAVA program without including any of the packages,such as "import java.io.*"; bcoz I instantly wrote a code without "import..." statement and runned the program on command Line & it worked. the code is: class Person { String name; int age; Person(String s,int a) { name = s; age = a; } accept() { System.out.println(name+"Hi!!!!!"); System.out.println(age); } } class Demo { public static void main(Strings args[])throws IOException { String name = args[0]; int age = Integer.parseInt(args[1]); Person p = new Person(name,age); p.accept(); } }

3 Answers  


in a constructor what happen if u call super and this in the same class? i know that it is not possible to call both in the same one? if we call what will happen?

10 Answers   ITC Infotech,


Why is logger singleton?

0 Answers  






Why set do not allow duplicates in java?

0 Answers  


State one difference between a template class and class template.

0 Answers   HAL,


When can an object reference be cast to an interface reference in java programming?

0 Answers  


Why can't we make a class private in java?

0 Answers  


What are the types of statement? explain

1 Answers   SysBiz,


Explain notify() method of object class ?

0 Answers  


What is the range of the short type?

0 Answers  


Categories