Is there any way to run a program (maybe C, C++, Java or Python) inside another Java program and get output.
I am developing a kind of Code-Editor and a kind of HackerRank clone with Java and I want the code editor to execute the program as well.
I have tried using
Runtime.getRuntime().exec("python Program.py")
in Java. But I do not find it that convincing. Is there any other way to achieve this??