made input argument independent of getopt flags
manages input with FILE*-Handles to use stdin (and pipes) or files: fixes #3