#include <cstdlib>
#include <iostream>
using namespace std;

class A {
public:
  A() {
    cout << "A()" << endl;  
  }
  ~A(){
    cout << "~A()" << endl;
  }
};

int main() {
  A * x = (A*)malloc(sizeof(A));
  A * y = new A;
  delete y;
  free(x);
}
