给定一个字符串值,如何将其显示在控制台的屏幕上?我必须写什么才能实现这一点?
作为一个例子,这是我到目前为止的代码:
public class Main {
public static void main(String[] args) {
String message = "I am a school student and just started learning Java.";
// What to write next?
}
}
Run Code Online (Sandbox Code Playgroud)
它可以工作,但显然还没有在控制台上显示该值。我必须写什么来展示它?
但我得到的只是这样: