How do I access command-line arguments?
Answer Posted / reejusri
In order to access the command arguments, the main()
function must have a prototype similar to the following.
int main(int argc, char * argv[])
The names argc and argv are usually used for the
parameters, but a programmer could use different names.
| Is This Answer Correct ? | 6 Yes | 4 No |
Post New Answer View All Answers
What is difference between structure and union?
What does return 1 means in c?
Devise a program that inputs a 3 digit number n and finds out whether the number is prime or not. Find out its factors.
When should the register modifier be used? Does it really help?
What is a static function in c?
What is typedf?
What is the use of getchar functions?
write a c program to calculate sum of digits till it reduces to a single digit using recursion
Can you please explain the scope of static variables?
which of the following statement is wrong a) mes=123.56; b) con='T'*'A'; c) this='T'*20; d) 3+a=b;
What are header files in c programming?
Why does the call char scanf work?
What is void pointers in c?
How to declare a variable?
what is ur strangth & weekness