For both languages, pass the file to stdin: make -C c ./c/a < input ./py/a.py < input