Declaration and Access Control Name the keyword that makes a variable belong to a class, rather than being defined for each instance of the class. abstract final static volatile native abstract final static volatile native ANSWER DOWNLOAD EXAMIANS APP
Declaration and Access Control The object is created with new keyword At run-time Depends on the code None of these At Compile-time At run-time Depends on the code None of these At Compile-time ANSWER DOWNLOAD EXAMIANS APP
Declaration and Access Control A package is a collection of Classes and Interfaces Classes Interfaces Editing tools Editing tools and Interfaces Classes and Interfaces Classes Interfaces Editing tools Editing tools and Interfaces ANSWER DOWNLOAD EXAMIANS APP
Declaration and Access Control What will be the output for the below code?public class Test{ static{ int a = 5; } public static void main(String[] args){ System.out.println(a); }} None of these Compile with error Runtime Exception 0 5 None of these Compile with error Runtime Exception 0 5 ANSWER DOWNLOAD EXAMIANS APP
Declaration and Access Control What will be the output?public class Test{ public static void main(String[] args){ String value = "abc"; changeValue(value); System.out.println(value); } public static void changeValue(String a){ a = "xyz"; }} abc xyz Compilation fails None of these Compilation clean but no output abc xyz Compilation fails None of these Compilation clean but no output ANSWER DOWNLOAD EXAMIANS APP
Declaration and Access Control What will be the output after compiling and running following program code?public class Test{ static int a; public static void main(String[] args){ System.out.println("one"); call(1); } static void call(int a){ this.a=10; System.out.println("two "+a); }} one two 1 one two 0 one two 10 Compile time error. None of these one two 1 one two 0 one two 10 Compile time error. None of these ANSWER DOWNLOAD EXAMIANS APP