1.

1. What is the output of the following program? # include <iostream.h>void main () { int a; a = 5 + 3*5; cout << a; } 2. How do 9, ‘9’ and “9” differ in C++ program?

Answer»

Here multiplication operation has more priority than addition. hence 

1. a = 5 + 15 = 20

2. Here 9 is an interger 

‘9’ is a character 

“9” is a string



Discussion

No Comment Found

Related InterviewSolutions