What does the code "cout<<(0==0);" print?
1) 0
2) 1
3) Compiler error: Lvalue required
Answer Posted / vivek satasia
Every expression or functon in programming paradigm works on
TRUE means 1 or FAlSE means o value.Ex- u can check this,
Suppose u write function like clrscr().It also returns
value.U can store it's value in a variable and can print
that variable.Like this expressio is first evaluated in from
of 0 or 1.
Here expression is 0==0 which is tru so it returns 1.
So,ans=1.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
what is difference between class template and template class?
What is object and class in oops?
#include
Get me an image implementation program.
What is difference between multiple inheritance and multilevel inheritance?
Why is polymorphism needed?
What is a null tree?
What is encapsulation in oops?
What is abstraction encapsulation?
What is the purpose of enum?
when to use 'mutable' keyword and when to use 'const cast' in c++
What is overloading in oop?
write a code for this:trailer recordId contains a value other than 99, then the file must error with the reason ‘Invalid RECORD_ID’(User Defined Exception).
What is and I oop mean?
What is difference between abstraction and encapsulation?