import org.python.util.PythonInterpreter; public class JythonExample { public static void main(String[] args) { PythonInterpreter interpreter = new PythonInterpreter(); interpreter.exec("import math"); interpreter.exec("print(math.sqrt(16))"); } }