What will happen when the following code is run:
int x;
while(x<100)
{
cout<<x;
x++;
}
1) The computer will output "0123...99"
2) The computer will output "0123...100"
3) The output is undefined
Answer Posted / ibrazileasum
The initial value of x is not defined to '0' hence the complier will not start from 0 as initial value. This is a garbage error to the compiler
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the example of polymorphism?
How do you define social class?
What is encapsulation example?
They started with the brief introduction followed by few basic C++ questions on polumorphism, inheritance and then virtual functions. What is polymorphims? How you will access polymorphic functions in C? How virtual function mechanism works?
can we make game by using c
Is this job good for future? can do this job post grduate student?
Where You Can Use Interface in your Project
What is encapsulation and abstraction? How are they implemented in C++?
Explain the concepts involved in Object Oriented programming.
What is class in oop with example?
What are the advantages of polymorphism?
How is class defined?
What does <> mean pseudocode?
what are the different types of qualifier in java?
What are the components of marker interface?