diff options
author | Patrick Simianer <p@simianer.de> | 2014-06-15 03:50:43 +0200 |
---|---|---|
committer | Patrick Simianer <p@simianer.de> | 2014-06-15 03:50:43 +0200 |
commit | 6ed9a9699997a2853ec1c9e91747c251e5cfc97b (patch) | |
tree | 56c96f18442fb06aeeb45cadc56355353a63ee99 /ccc/class.cc | |
parent | 258e1b92ebbfdebefabc120969ab87c3d8b75c3d (diff) |
damn
Diffstat (limited to 'ccc/class.cc')
-rw-r--r-- | ccc/class.cc | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/ccc/class.cc b/ccc/class.cc deleted file mode 100644 index b493b51..0000000 --- a/ccc/class.cc +++ /dev/null @@ -1,31 +0,0 @@ -#include <iostream> - -using namespace std; - - -class A { - public: - A(int a):_a(a) {} - int geta() { - return _a; - } - static int _b; - private: - int _a; -}; - -int A::_b = 0; - -int main(void){ - A a(2); - A *b = new A(2); - cout << b->geta() << endl; - cout << b->_b << endl; - cout << a._b << endl; - A::_b = 42; - cout << b->geta() << endl; - cout << b->_b << endl; - cout << a._b << endl; - return 0; -} - |