But now that you have it working... what you're doing has basically nothing to do with OOP. :)
Some rules of thumb for OO design:
1) Don't use member variables to store intermediate results of calculations. Use local variables inside the member functions. This is the same idea as not using globals when you could use a local inside a free function: restrict scope as much as possible. The purpose of member variables is to remember data "between" calls to the member functions. It forms the logical 'state' of the object.
2) Don't use names like "Manager" for classes. Figure out what it is that the class
does, and give it an appropriate name. Your class adds two numbers, so Adder is a reasonable name.
3) Encapsulate an object's state. This does NOT mean making getters and setters for everything. It means designing an interface that makes sense.
4) Don't construct an object until you have all the information you need to put it into a valid state. Then give all that information to the constructor, so the object can be in a valid state right away.
5) Don't write things that you don't have to write. In C++, it's actually very rare to have to write a destructor yourself, if you are using modern tools. (One notable exception: if you are going to use inheritance for polymorphism, you need a 'virtual' destructor defined in the base class.)
Taking these principles into account, and using some modern C++ idioms, we can transform even this simple example into something quite different (although still very useless ;) ):
#include <iostream>class adder { private: int x, y; public: adder(int x, int y) : x(x), y(y) {} int sum();}; // LOL, I initially forgot the semicolon, too!// Been working in Java too much recently, I guess.// You don't even need 'z' at all.int adder::sum() { return x + y; }int main() { using namespace std; cout << "Please enter two numbers: " << endl; cin >> x; cin >> y; // We don't need to give the adder instance a name, because it's only // used once: cout << x << " plus " << y << " equals " << adder(x, y).sum() << endl;}