Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

halp

Name: Anonymous 2013-04-21 12:02

what's wrong with this piece of C code /prog/?

#include <stdio.h>
int main (int argc, char *argv[])
{
        printf("%s %s %s \n",argv[1],argv[3],argv[5]);

        return 0;
}

Name: Anonymous 2013-04-21 12:31

depends what its supposed to do. right now it prints the 1st, 3rd and 5th command line argument separated by spaces assuming you supply at least 5 arguments, otherwise behavior is undefined, is that what you want?

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List