JAVA Constructors and Methods In which area of memory, the system stores parameters and local variables whenever a method is invoked? Stack Storage Area Heap Array Stack Storage Area Heap Array ANSWER DOWNLOAD EXAMIANS APP
JAVA Constructors and Methods class MyClass{int i;int j;public MyClass(int i, int j){this.i = i;this.j = j;}public void call(){System.out.print("One");}}public class Test{public static void main(String args[]){MyClass m = new MyClass(); //line 1m.call(); //line 2}} Compilation fails due to an error on line 2 Compilation fails due to an error on line 1 Compilation succeed but no output. One Compilation fails due to an error on line 2 Compilation fails due to an error on line 1 Compilation succeed but no output. One ANSWER DOWNLOAD EXAMIANS APP
JAVA Constructors and Methods What is Math.floor(3.6)? 3.0 3 4.0 4 3.0 3 4.0 4 ANSWER DOWNLOAD EXAMIANS APP
JAVA Constructors and Methods public class Test { }What is the prototype of the default constructor? Test(void) None of these public Test(void) public Test( ) Test( ) Test(void) None of these public Test(void) public Test( ) Test( ) ANSWER DOWNLOAD EXAMIANS APP
JAVA Constructors and Methods Determine output of the following program.public class Test{ public static void main(String args[]){ System.out.println( Math.floor( Math.random( ) ) ) ; }} 10.0 0.5 1.0 0.0 10.0 0.5 1.0 0.0 ANSWER DOWNLOAD EXAMIANS APP
JAVA Constructors and Methods Determine output:public class Test{ public static void main(String args[]){ MyClass obj = new MyClass(); obj.val = 1; obj.call(obj); System.out.println(obj.val); }}class MyClass{ public int val; public void call(MyClass ref){ ref.val++; }} 2 1 Compilation Error None of these 3 2 1 Compilation Error None of these 3 ANSWER DOWNLOAD EXAMIANS APP