Unity Interview Question

What would be your approach at creating a barrel generator.