Can anyone tell me how to round a double value to x number of decimal places in Swift?
I have:
var totalWorkTimeInHours = (totalWorkTime/60/60)
Swift 4, Xcode 10
yourLabel.text = String(format:"%.2f", yourDecimalValue)