Data Types and Variables Automatic type conversion in Java takes place when Two type are compatible and size of destination type is shorter than source type. All of these Two type are compatible and size of destination type is equal of source type. Two type are compatible and size of destination type is larger than source type. Two type are compatible and size of destination type is shorter than source type. All of these Two type are compatible and size of destination type is equal of source type. Two type are compatible and size of destination type is larger than source type. ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables Which of the following automatic type conversion will be possible? long to int byte to int int to long short to int long to int byte to int int to long short to int ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables What would be the output of the following fraction of code ?int Integer = 34 ;char String = 'S' ;System.out.print( Integer ) ;System.out.print( String ) ; 34 S Does not compile as Integer and String are API class names. Throws exception. 34 S 34 S Does not compile as Integer and String are API class names. Throws exception. 34 S 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 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); }} Compilation Error float double Exception is thrown at runtime Compilation Error float double Exception is thrown at runtime ANSWER DOWNLOAD EXAMIANS APP
Data Types and Variables The following program:public class Test{ static boolean isOK; public static void main(String args[]){ System.out.print(isOK); } } Prints false Will not compile as boolean is not initialized Will not compile as boolean can never be static Prints true Prints false Will not compile as boolean is not initialized Will not compile as boolean can never be static Prints true ANSWER DOWNLOAD EXAMIANS APP