Im not sure if it is possible, but would like to know if i can use the result of a main() function as the command line argument for another program. im currently using gcc compiler on linux so i figure it would look something like this:
./listcommandlinearugments ./generaterandomstring
but this does not work... in the above example the first program (listcommandlinearguments) simply lists ./generaterandomstring as a command line arugment instead of using the result of the main funtion (0) because it was int main() and returned 0.