How Can I Update Java?

Question:
Hey i want to ask that i want to compile a file but to do it i need the java version 8 to 16 how can i change the shell java compiler version??

Replit Profile: https://replit.com/@ankuush19

3 posts were split to a new topic: We ran into an internet problem

Haven’t done java before, but ghostwriter said to add this to pom.xml:

<properties>
    <maven.compiler.source>16</maven.compiler.source>
    <maven.compiler.target>16</maven.compiler.target>
  </properties>

I want to do it for shell