I’m making a java program that requires me to use python as well. What I want to do is get 3 values from the java code and then call a function from a python file with the 3 values as parameters. How do I go about this?
So far I’ve tried opening the file with simply:
File file = new File("python file location");
Desktop desktop = Desktop.getDesktop();
if(file.exists()) desktop.open(file);
and catching any IOException but this just runs the entire python file and not the specific function.
New contributor
Xter 380 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.