Advertisement
Qwarri

Struct#Qwarri#001

Oct 19th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.21 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. struct Struct
  5. {
  6.     int age = 19;
  7.  
  8.     int returnAge()
  9.     {
  10.         return this->age;
  11.     }
  12. };
  13.  
  14. void main()
  15. {
  16.     Struct X;
  17.  
  18.     cout << X.returnAge() << endl;
  19.     system("pause");
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement