<div dir="ltr"><div>My Java project, which uses Gradle 7.4, told me that this version of Gradle is incompatible with Java 18. I had a look <a href="https://docs.gradle.org/current/userguide/compatibility.html">here</a> and was advised to use Java 17. So, I tried to remove Java 18 using "sudo apt remove openjdk-18-jdk" followed by "sudo apt install openjdk-17-jdk". When I run java --version I get the following result:</div><div><br></div><div style="margin-left:40px">openjdk 18.0.2-ea 2022-07-19<br>OpenJDK Runtime Environment (build 18.0.2-ea+9-Ubuntu-222.04)<br>OpenJDK 64-Bit Server VM (build 18.0.2-ea+9-Ubuntu-222.04, mixed mode, sharing)<br></div><div><br></div><div>I have tried to run this in a fresh CLI window, and the results are the same,</div><div><br></div><div>What do I do now?<br></div></div>