$pid = open(PROG, "| /path/to/program -a v1 -b v2 "); print PROG "input to program\n"; close(PROG);