class Test { public static void main(String[] args) throws Exception { byte a = (byte)1, b = (byte)2; byte c = a+b; System.out.println(c); }}
Standard input is empty
Main.java:4: error: incompatible types: possible lossy conversion from int to byte byte c = a+b; ^ 1 error
Standard output is empty
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!