#include <iostream>
using namespace std;
struct wow {
int x;
};
int main() {
wow a;
a.x = 22;
int c = a.x;
int *b = new int;
cout << c;
return 0;
}
option:
No output
0
22
-(11)
Will not compile
Answer Posted / tiger
22
| Is This Answer Correct ? | 11 Yes | 4 No |
Post New Answer View All Answers
What is the main feature of oop?
What is encapsulation in simple terms?
class CTest { public: void someMethod() { int nCount = 0; cout << "This is some method --> " << nCount; } }; int main() { CTest *pctest; pctest->someMethod(); return 0; } It will executes the someMethod() and displays the value too. how is it possible with our creating memory for the class . i think iam not creating object for the class. Thanks in Advance... Prakash
What is this pointer in oop?
Plese get me a perfect C++ program for railway/airway reservation with all details.
What are constructors in oop?
can we make game by using c
What is encapsulation and abstraction? How are they implemented in C++?
What is object in oop?
What is the problem with multiple inheritance?
What is an advantage of polymorphism?
Write a program to reverse a string using recursive function?
What is a superclass in oop?
What polymorphism means?
What is meant by oops concept?