Сравнение Классов vs Структур vs Объединений

struct & class & union
/*Here, C++ program constructor in struct*/
#include <iostream>
using namespace std;

struct Hello
{
public:     //by default also it is public
  Hello();
  ~Hello();
}hello;

Hello::Hello()
{
  cout << "calling constructor...!" << endl;
}

Hello::~Hello()
{
  cout << "calling destructor...!" << endl;
}

int main()
{
  Hello obj;      //creating a hello obj, calling hello constructor and destructor 

  system("pause>nul");
  return 0;
}