for _, item := range stateList { fmt.Printf("item: %v\n", item) stateitem += strconv.FormatInt(int64(item), 10) + "," } stateitem = strings.TrimRight(stateitem, ",")