Infosys interview question

Why string is immutable? Java program to sort map by value