To install the Java 11 JDK on a Raspberry Pi, you can follow these steps:
Download the Java 11 JDK Linux ARM 32-bit tar.gz file from the Oracle website.
Extract the tar.gz file:
tar -xvf openjdk-11.0.10_arm-32.tar.gz
sudo mv jdk-11.0.10 /usr/lib/jvm/jdk-11
PATH
environment variable:sudo nano /etc/environment
Add the following line to the end of the file:
PATH="/usr/lib/jvm/jdk-11/bin:${PATH}"
source /etc/environment
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk-11/bin/java 1
java -version
Note that these steps will install the Oracle version of Java 11. If you prefer to install the OpenJDK version of Java 11, you can download it from the OpenJDK website.
For more information on installing Java on a Raspberry Pi, you can refer to the Oracle documentation or the OpenJDK documentation.