자바 + 파이썬.jpg

from reddit
Here is an example of running Python code inside a simple Java application
import org.python.util.PythonInterpreter;
public class JythonHelloWorld {
public static void main(String[] args) {
try(PythonInterpreter pyInterp = new PythonInterpreter()) {
pyInterp.exec("print('Hello Python World!')");
}
}
}
Here is an example of using Java from Python code
Here is an example of using Java from Python code
from java.lang import System # Java import
print('Running on Java version: ' + System.getProperty('java.version'))
print('Unix time from Java: ' + str(System.currentTimeMillis()))https://github.com/jython/jython
어?
