Page 1 of 1

2. What is the result of attempting to compile and run the program? class Question2 { static byte a; static short b; sta

Posted: Fri May 20, 2022 11:34 am
by answerhappygod
2 What Is The Result Of Attempting To Compile And Run The Program Class Question2 Static Byte A Static Short B Sta 1
2 What Is The Result Of Attempting To Compile And Run The Program Class Question2 Static Byte A Static Short B Sta 1 (35.29 KiB) Viewed 27 times
jave .Pelsse The coding and output answer must screenshot from
compiler.
And give the explanation for each output.
2. What is the result of attempting to compile and run the program? class Question2 { static byte a; static short b; static char c; static int d; static long e; static String s; public static void main(String[] args) { System.out.println(a+b+c+d+e+s); } } Coding (from compiler): Output (from compiler): Explanation: (5 marks)