int main() {
Employee *e = new Employee();
delete e;
delete e;
...
delete e;
return 0;
}
You get undefined behaviour if you try to delete
an object through a pointer more than once.
This means that pretty much anything can happen from 'appearing to work' to 'crashing' or something completely random.