multiple input file functionality