Files
freeCodeCamp/guide/chinese/swift/hello-world/index.md
2018-10-16 21:32:40 +05:30

26 lines
518 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: Hello World Swift
localeTitle: Hello World Swift
---
你好,世界
只有我们必须将方法`print("Hello World")` 从库UIKit添加到类ViewController的函数`viewDidLoad()`中:
\`\`\`斯威夫特 导入UIKit
class ViewControllerUIViewController {
```
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view, typically from a nib.
print("Hello World")
}
```
} \`\`\`
##输出: \`\`\`
> 你好,世界 \`\`\`