functions getting arguments and returning values; input files in separate dir