Skip to content

Instantly share code, notes, and snippets.

@NicolaM94
Created March 30, 2023 22:34
Show Gist options
  • Save NicolaM94/6467adb5daf949750075fb6ae13dfea6 to your computer and use it in GitHub Desktop.
Save NicolaM94/6467adb5daf949750075fb6ae13dfea6 to your computer and use it in GitHub Desktop.
Comparison of two int arrays in Go
func Compare (arrayA, arrayB []int) bool {
for i := range arrayA {
if arrayA[i] != arrayB[i] {
return false
}
}
return true
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment