30 lines
		
	
	
		
			502 B
		
	
	
	
		
			Markdown
		
	
	
	
	
	
		
		
			
		
	
	
			30 lines
		
	
	
		
			502 B
		
	
	
	
		
			Markdown
		
	
	
	
	
	
|   | --- | ||
|  | title: Hello World Swift | ||
|  | --- | ||
|  | 
 | ||
|  |  ## Hello World | ||
|  | 
 | ||
|  | Only we have to add the method `print("Hello World")` (from the library UIKit) to the function `viewDidLoad()` of the class `ViewController: | ||
|  | 
 | ||
|  |  ```Swift | ||
|  |  import UIKit | ||
|  | 
 | ||
|  | class ViewController: UIViewController { | ||
|  | 
 | ||
|  |     override func viewDidLoad() { | ||
|  |         super.viewDidLoad() | ||
|  |         // Do any additional setup after loading the view, typically from a nib. | ||
|  |          | ||
|  |         print("Hello World") | ||
|  |          | ||
|  |     } | ||
|  | 
 | ||
|  | 
 | ||
|  | } | ||
|  |  ``` | ||
|  | 
 | ||
|  |  ## Output: | ||
|  |  ``` | ||
|  |  >Hello World | ||
|  |  ``` |