I used the following code and i have a couple of issues with it
int SomeInts = [1,2,3,4,5,6,7,8,9,10]
func reverseOrderFunc(num1:Int,num2,Int)->Bool{
if num1<num2
{
return false
}
return true
}
sort(SomeInts,reverseOrderFunc)
1.) why do we return bool
2.) xcode playground displays an error in the sort statement that it cannot invoke argument list of type ([Int],Int,Int)->Bool
Kindly help me out of this confusion
Regards,
Navjot