Data Types and Variables What is the output for the below code ?1. public class Test{2. public static void main(String[] args){3. int i = 010;4. int j = 07;5. System.out.println(i);6. System.out.println(j);7. }8. } 8 7 None of these Compilation fails with an error at line 3 Compilation fails with an error at line 5 10 7 8 7 None of these Compilation fails with an error at line 3 Compilation fails with an error at line 5 10 7 ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables What will the output of the following program?public class Test{ public static void main(String args[]){ float f = (1 / 4) * 10; int i = Math.round(f); System.out.println(i); }} 0 25 2.5 2 3 0 25 2.5 2 3 ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables Which of the following automatic type conversion will be possible? byte to int long to int int to long short to int byte to int long to int int to long short to int ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables Determine output:public class Test { static void test(float x){ System.out.print("float"); } static void test(double x){ System.out.print("double"); } public static void main(String[] args){ test(99.9); }} double float Compilation Error Exception is thrown at runtime double float Compilation Error Exception is thrown at runtime ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables Java is a ........... language. strongly typed None of these weakly typed moderate typed strongly typed None of these weakly typed moderate typed ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables What will be output of following program?public class Test{ public static void main(String[] args){ byte b=127; b++; b++; System.out.println(b); }} -127 2 Compiler error None of these 129 -127 2 Compiler error None of these 129 ANSWER DOWNLOAD EXAMIANS APP