I am trying to initialize *argv with these values : test_file model result
Can anyone help me how to directly initialize the argv instead of using command line. I am doing it like this:
*argv[]= {"test_file","model","output",NULL};
but its not working. I know its simple but i am new to programming. Can anyone help me?
One thing to be aware of is that the standard
argvstrings are permitted to be modified. These replacement ones cannot be (they’re literals). If you need that capability (which many option parsers might), you’ll need something a bit smarter. Maybe something like:That gets called like so: