一个是标准输出
一个是标准错误输出
在不同的容器,System.out.println() 和System.err.println()会输出
不同的文件中。

解决方案 »

  1.   

    System.err.println()不能被重定向
      

  2.   

    assume you have a class test1 written with System.err and
    you have a class test2 written with Sytem.outwhen you try :java test1>>log.txt, you will see the output displayed on the console
    when you try :java test2>>log.txt, you will never get output ont the console and you can find those output in the log.txtthat's the distinction between them.hope it helps.
      

  3.   

    System.out.println() 是标准输出
    System.err.println() 是标准错误输出
    默认情况下都是将结果输出到控制台,不过可以对其进行重定向从而改变其默认输出的方式。