I am writing a program for evaluating C ++ code that students present. Now it uses a system call to compile each source file, then redirects the input file to a file and calls new executable files in the processes and looks for output for certain lines. It also allows me to have a timeout for processes for emergency programs.
Is there a better way to do this than a system call? Or is the best way to do this overall?
source
share