Created
June 13, 2016 07:10
-
-
Save asm-jaime/1e79abc8e5ba1cb446de916ca9b8e5d7 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
import ( | |
"sort" | |
) | |
type Int64Slice []int64 | |
func (slice Int64Slice) Len() int { return len(slice) } | |
func (slice Int64Slice) Less(i, j int) bool { return slice[i] < slice[j] } | |
func (slice Int64Slice) Swap(i, j int) { slice[i], slice[j] = slice[j], slice[i] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment