📜  如何在 Java 代码示例中添加子字符串

📅  最后修改于: 2022-03-11 14:52:41.406000             🧑  作者: Mango

代码示例1
class scratch{
    public static void main(String[] args) {
        String hey = "Hello World";
        System.out.println( hey.substring(0, 5) );
        // prints Hello;
    }
}