1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
#include <iostream> using namespace std; int main() { int *a = new int[5]; int *b = new (int[5]); int n = 5; int *c = new int[n]; int *d = new (int[n]); return 0; }
1 2 3
In function 'int main()': Line 12: error: ISO C++ forbids variable-size array compilation terminated due to -Wfatal-errors.