main + inputfile modified again