Reverse String Using While Loop Java