0
What we can write between this : int main(HERE) in C language
I actually ask google but i don't find a clear answer
1 Respuesta
+ 2
main accepts 0 or 2 arguments
int main() // unspecified amount of args
int main(void) // no args
int main(int argc, char** argv) // argc is the number of arguments from the command line, argv is an array (or vector
since it differs when you run main with different amount of cmd line arguments) of c-style strings which are the file name + command line arguments and will have the length of argc
int main(int argc, char* argv[]) // the same as the one before but I like it better because it tells me that argv is an array of char*
I believe you can make either of them const but there's no reason to...