1、 System.out.println(" "+a+b); System.out.println(a+b+" "); 两者的区别: 第一句:前后直接拼接 第二句:先执行加法运算,后拼接 总结:看字符串所在位置