What is length in java?
No Answer is Posted For this Question
Be the First to Post Answer
What is the difference between normal report & matrix report?
How to instantiate static nested classes in java?
Can list contain null in java?
How can constructor chaining be done using this keyword?
How can you write a loop indefinitely in java programming?
import java.io.*; class Demo { public static void main(String args[]) { File f=new File("1234.msg"); String arr[]=f.list(); System.out.println(arr.length); } }
Can I declare class as static or private?
What is busy spin, and why should you use it?
Given: 10. interface A { void x(); } 11. class B implements A { public void x() { } public voidy() { } } 12. class C extends B { public void x() {} } And: 20. java.util.List list = new java.util.ArrayList(); 21. list.add(new B()); 22. list.add(new C()); 23. for (A a:list) { 24. a.x(); 25. a.y();; 26. } What is the result? 1 Compilation fails because of an error in line 25. 2 The code runs with no output. 3 An exception is thrown at runtime. 4 Compilation fails because of an error in line 20.
Write a program to reverse array in place?
Where is java located?
What is function and its uses?