Linux users will also have to make sure they have some 32-bit libraries installed if they are running a 64-bit version of the operating system. If you need more assistance or want to use a package manager to install Sun Java, you'll need to refer to the documentation for your particular distro. (OpenJDK is now bundled with Android Studio which includes the SDK as well as a development environment) and you'll find complete instructions to get it installed at the OpenJDK website. OpenJDK also works for most things you'll need to do with the SDK. You can find x86 and 圆4 binaries for Sun Java from Oracle at their website. If you can't install Java, maybe you're not yet ready to use the Android SDK. Again, if this gives you any trouble, stop what you're doing and learn a bit more about your computer. If you did, install it again - you should know how to do that if you knew how to uninstall it.
For most things, you'll be doing with the SDK, both Open Java and Sun Java from Oracle (yes, that Oracle) will work. You'll need a working version of Java to run the SDK components. Source: Android Central (Image credit: Source: Android Central)