I am trying to convert a string (const char* argv[]
) to a double
precision floating point number:
int main(const int argc, const char *argv[]) {
int i;
double numbers[argc - 1];
for(i = 1; i < argc; i += 1) {
/* -- Convert each argv into a double and put it in `number` */
}
/* ... */
return 0;
}
Can anyone help me? Thanks