I have a M1 macbook, I am working on my java project,
when I run
The output was
But when I try to get the version using
then this was the output
I verified that the system also has javac at /usr/bin/javac
I am unable to run the java file to compile
Thanks
when I run
Code Block $ which java
The output was
Code Block /usr/bin/java
But when I try to get the version using
Code Block $ java --version
then this was the output
Code Block The operation couldn’t be completed. Unable to locate a Java Runtime.
Code Block Please visit http://www.java.com for information on installing Java.
I verified that the system also has javac at /usr/bin/javac
I am unable to run the java file to compile
Thanks