1 comment

sorted by: hot top controversial new old
[–] 2 points 3 months ago*

tl;dr arr[len(arr)] is wrong; arr[len(arr)-1] is right because Go uses zero-based indexes like a bunch of other languages.

  • source