I am using VC, seemsI have to convert the type in this program.
double *tptr = (double*) malloc(n*sizeof(double));
after using this statement, there is no errors, faint. Do you know why? Is it because of VC's complier settings?
suggest use: double *tptr = new double[n]
if you use malloc(), you must tell which kind of type you want to convert.
suggest use new and delete in C++:
double *tptr = new double[n];
...
delete tptr;
suggest use new and delete in C++:
double *tptr = new double[n];
...
delete tptr;