源代码
package hello // 可选的包头 fun main(args: Array
) { // 包级可见的函数,接受一个字符串数组作为参数 println("Hello World!") // 分号可以省略 }
运行结果