Remove at Index

Examples Filter
package main

import "fmt"

func main() {
  
  s := []int{1, 2, 3, 4, 5}
  fmt.Println(s)
  
  removeIdx := 3
  s = append(s[:removeIdx], s[removeIdx+1:]...)
  fmt.Println(s)
}
Last Run  :
[1 2 3 4 5]
[1 2 3 5]