Created
January 21, 2017 06:35
-
-
Save frankxzx/31a4acc760f2c8565b650a90d866fade to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
typealias Check<U> = (U, U) -> Bool | |
func compare<T>(ls: T, rs: T, check: Check<T>) -> Bool { | |
return check(ls, rs) | |
} | |
let a = compare(ls: 2, rs: 3) { $0 > $1 } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment