System.out.print("你好");
output: ??
Process finished with exit code 0
System.out.print("你好");
output: ??
Process finished with exit code 0
This seems to be a known issue of IntelliJ IDEA:
Try the workaround from the issue description:
Click Run | Edit configurations, add the -Dfile.encoding=<your_system_default_encoding> (example: -Dfile.encoding=gbk in Chinese encoding) in this application's VM options.