Installing Java on Endless 3.3.19 fails

Hi Endless team. I am trying to install Java JDK from java.com or Oracle Jdk, but it doesn’t work. I downloaded the file and started installing in the terminal but the terminal always shows errors and can’t find files /directories.

Can you give me any instruction to install JDK or JRE?

As of version 3.0 Endless OS has adopted Flatpak, a new application distribution system
https://support.endlessm.com/hc/en/articles/115001980483-O-que-é-o-Flatpak-