install java 8 on mac code example
Example 1: brew install jdk 8
brew tap adoptopenjdk/openjdk
brew cask install adoptopenjdk8
Example 2: how to install java 8 on terminal os
brew tap adoptopenjdk/openjdk
brew cask install adoptopenjdk8
brew cask install adoptopenjdk9
brew cask install adoptopenjdk10
brew cask install adoptopenjdk11
brew cask install java8