Code Room
Code reviewHard
Question
Review this Go function that builds a slice of ids from a large result set. It shows up high in allocation profiles.
What a strong answer looks like
Separate real bugs from style. Rank issues by severity, point at the root cause rather than the symptom, and suggest a concrete fix — specific and kind.
Learn the concepts
func collectIDs(rows []Row) []int64 { var ids []int64 for _, r := range rows { ids = append(ids, r.ID) } return ids}Run or narrate your approach, then ask the coach.