How to store a file name in a variable when redirecting to default entry without using argv. Example of execution: ./a. out < filename.txt
This is not a question of shell?
– Marcelo Shiniti Uchimura
No, the problem arises when I put the minor symbol to redirect the input, if the execution is . /a. out filename.txt the argc account 2 and account 1 executing . /a. out < filename.txt
– speeds0n
Of course; redirecting is a feature of shell.
– Marcelo Shiniti Uchimura