I used the command brew install openjdk@11
to install Java on my mac. But when I run
java --version
, I get the following message:
The operation couldn’t be completed. Unable to locate a Java Runtime.
Please visit http://www.java.com for information on installing Java. I have a few questions:
- How do I install JRE using HomeBrew?
- Which JRE version do I need to install?