QUESTIONS: 1. For the program given below, which line generate errors after compile and run. Show your coding and output
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
QUESTIONS: 1. For the program given below, which line generate errors after compile and run. Show your coding and output
from compiler.
And give the explanation for each output.
QUESTIONS: 1. For the program given below, which line generate errors after compile and run. Show your coding and output. Explain why error happen? public class Questionl { public static void main(String[] args) { byte bl = -128, // 1 byte b2 = 127; // 2 short s1 = -32769; // 3 short s2 = 32767; // 4 char cl = 0; // 5 } Coding (from compiler): Output (from compiler): Explanation: (5 marks)