// ohaiwurld.cpp #include <iostream> #include <stdio.h> int main(int argc, char* argv[]) { printf("o hai, wurld!\n"); if (argc > 1) { printf("we haz argumentz!\n"); printf("argz = "); for (int i = 1; i < argc; i++) { printf("%s ", argv[i]); } printf("\n"); } return 0; } $ g++ ohaiwurld.cpp -o ohaiwurld $ ./ohaiwurld lolcatz cheezburger can haz o hai, wurld! we haz argumentz! argz = lolcatz cheezburger can haz
never thought i’d be messing with this. i don’t know if it will be part of a solution i’m looking into at work, but it was a neat moment to step back into this.