Q:

What is a block in Swift 4 and how do I fill in the parameter of the scheduledTimer method?

class func scheduledTimer(withTimeInterval interval: TimeInterval, 
                  repeats: Bool, 
                    block: @escaping (Timer) -> Void) -> Timer

A:

There are no further parameters.
The closure is a replacement for target and action and userInfo is not needed either because the closure can capture values in the method before the call.
Here is an example:
var myTimer : Timer?

---

var counter = 0  
myTimer = Timer.scheduledTimer(withTimeInterval: 1.0, repeats: true) { timer in 
    counter += 1
    print(counter)
    if counter == 10 { 
       timer.invalidate() 
       myTimer = nil
       print("timer stopped")
    }          
}

