Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import UIKit
- class ViewController: UIViewController {
- func plus(num1: Int, num2: Int) -> Int {
- let result = num1 + num2
- return result
- }
- override func viewDidLoad() {
- super.viewDidLoad()
- let a = 10
- let b = 20
- let sum = plus(num1: a, num2: b)
- print(sum)
- }
- }
Add Comment
Please, Sign In to add comment