// rememb-o-matic
 #include <iostream>
 #include <new>
 using namespace std;
 int main ()
 {
   int i,n;
   int * p;
   cout << "How many numbers would you like to type? ";
   cin >> i;
   p= new (nothrow) int [i];
   if (p == 0)
     cout << "Error: memory could not be allocated";
   else
   {
     for (n=0; n<i; n++)
     {
       cout << "Enter number: ";
       cin >> p[n];
     }
     cout << "You have entered: ";
     for (n=0; n<i; n++)
       cout << p[n] << ", ";
     delete[] p;
   }
   return 0;
 }
Now,
why is their a bracket enclosed in variable i?
 p= new (nothrow) int [i];
why are their 2 for statements and what does a for statement do exactly?
Why is it deleting []p instead of the variable p?
 
     
     
     
     
    