Question 1: What is the output of the following snippet? #include <iostream> using namespace std; class A { friend class B; private: int field; public: int set(int x) { return field = ++x; } int get() { return ++field; } }; class B { public: void …
Read More »