programming-examples/c/_Basic/C Program to Print the Program Name and All its Arguments.c

14 lines
319 B
C
Raw Normal View History

2019-11-15 12:59:38 +01:00
/*
* C Program to Print the Program Name and All its Arguments
*/
#include <stdio.h>
void main(int argc, char *argv[]) /* command line Arguments */
{
int i;
for (i = 0; i < argc; i++)
{
printf("%s ", argv[i]); /* Printing the string */
}
printf("\n");
}