Computer Science, asked by raj59446, 1 month ago

18.
Q.24.int a=8,b=5,c=3; System.out.println(a+"+"+b+"+"+c+"="+(a+b+c)); what is the output.

Answers

Answered by BrainlyProgrammer
6

Answer:

Given, a=8,b=5,c=3

System.out.println(a+"+"+b+"+"+c+"="+(a+b+c));

Here, the output will be...

8+5+3=16

Note:-

  • Integer variables seperated by + and enclosed in brackets are added.
  • Integer variables seperated by string are concatenated.
  • Integer variables followed by string and not enclosed in brackets are concatenated
  • Integer variables followed by string and enclosed in brackets are added
Similar questions