When running a program on GDB, usually, the arguments for the program are given at the run command. Is there a way to run the program using GDB and as well as g
Another way to do this, which I personally find slightly more convenient and intuitive (without having to remember the --args parameter), is to compile normally, and use r arg1 arg2 arg3 directly from within gdb, like so: