Infosys interview question

Why is Java a platform independent language?