MacOS users
If you do not want to make JDK9 as the primary Java on your MacOS, here's something to try out.

What JDK am I using ?

// Tells you which JDKs you have
$ /usr/libexec/java_home -verbose

Can I set JDK8 or JDK9 to be my default JAVA_HOME each time I log into my terminal ?

// You can set that export command in your ~/.profile
// and/or ~/.bashrc to permanently set JAVA_HOME
// for all shells/terminals/applications.
export JAVA_HOME="`/usr/libexec/java_home -v '1.8*'`"
// Set JAVA_HOME to be Java 9 for the terminal
// window you are in
export JAVA_HOME="`/usr/libexec/java_home -v '1.9*'`"

Linux/MacOS users
How can I switch between different versions of the JDK if I have multiple of them ?

-> /help
Type a Java language expression, statement, or declaration.
Or type one of the following commands:
{
.
.
.
[Options]
.
.
.
}
Supported shortcuts include:
<tab> -- show possible completions for the current text
Shift-<tab> -- for current method or constructor invocation, show a synopsis of the method/constructor