更新特定位置的字符串值2

时间:2017-05-08 10:33:47

标签: java

{
        // TODO Auto-generated method stub

        StringBuilder s = new StringBuilder ("1234S" );

        int t = s.charAt(4);

        t =t+2;

        s.setCharAt(3, 't');
    }

}

0 个答案:

没有答案