int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b;
System.out.println("The value is"+a+b+c;

Answers were Sorted based on User's Feedback



int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / manju

(I tried this pgm)
It will give compilation error(like insert ') ' )
if u insert that bracket and then run ,the answer will be
102030.(bcz its treated only as strings)

Is This Answer Correct ?    1 Yes 2 No

int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / selvan

it gives two error one is (; expected error ) second is ()
expected error).

Is This Answer Correct ?    0 Yes 1 No

int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / ravikiran

260

Is This Answer Correct ?    0 Yes 1 No

int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / suresh

this program is error.

Is This Answer Correct ?    4 Yes 8 No

int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / suresh

50
40
30

Is This Answer Correct ?    3 Yes 8 No

int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / suresh

130

Is This Answer Correct ?    1 Yes 6 No

int a=10,b=20,c=30 a= b+c;b=a+c;c=a+b; System.out.println("The value is"+a+b+c; ..

Answer / suresh

120

Is This Answer Correct ?    1 Yes 9 No

Post New Answer

More Core Java Interview Questions

Write the algorithm to check the number non-leaf nodes in a tree.

0 Answers   Amdocs,


What does regex mean?

0 Answers  


Is null a string or object in java?

0 Answers  


what is optional in java 8?

0 Answers  


Explain about the interpreter in java?

0 Answers  






What are different types of access modifiers?

3 Answers  


What does exp mean in math?

0 Answers  


What is difference between path and classpath?

0 Answers  


What is nullpointerexception in java?

0 Answers  


Can we define package statement after import statement in java?

0 Answers  


What does you mean in math?

0 Answers  


What are the methods to rectify ambiguities in the interfaces in JAVA?

0 Answers   CGI,


Categories