Miscellany
public c v1 · immutable int ch; char *ifwanted; char *sleeplen; while ((ch = getopt(argc, argv, "i:t:")) != -1) { switch (ch) { case 'i': ifwanted = optarg; printf("You want '%s'\n", optarg); break; case 't': sleeplen = optarg; printf("You want '%s'\n", optarg); break; case '?': default: break; } argc -= optind; argv += optind; }