by Queue29 · 12y ago · 0 comments
Ignoring logic bugs sounds like a horrible idea
arr = arr[:N]
...compared how it has to be done to avoid a panic: if len(arr) > N {
arr = arr[:N]
}
Not a big deal though, just slightly more verbose.