Setting the Default Java Version

You might have 2 different versions of Java on your system. To set one as the default , use the command:

sudo alternatives ––config java
The system displays a list of different Java versions. If you like the default, press Enter.

If you want to change it, type the number of the version you want, then press Enter.

Comments