# Convert Code to Another Language

Source: https://coremesh.online/prompts/convert-code-to-another-language/

Convert this Python code to idiomatic Go:

```
def chunks(xs, n):
    return [xs[i:i+n] for i in range(0, len(xs), n)]
```

Keep the behaviour identical. Use Go conventions for naming, errors and types rather than copying Python style.
After the code, list any place where the two languages behave differently (integer division, nil/None, slicing, errors) and how you handled it.
