a question on "argc >3 ? argv[i]:NULL"
Mar 4, 2011 at 5:17am
There is code snippet
1 2 3 4 5 6 7 8 9
|
Int main(int argc, char *argv[ ])
{
FILE *f;
f = fopen(argv[i], "r");
If (grep(argv[1], f , argc >3 ? argv[i]:NULL)>0) {
/* do sth */
}
}
|
I do not understand how does the logic in if mean? In specific, what does
argc >3 ? argv[i]:NULL
mean? Thanks
Mar 4, 2011 at 6:22am
Topic archived. No new replies allowed.