Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
sol2-configtasks.ts
let idx =1, tasksQueue = Array(numberOfTasks).fill(1)
.map(v => Math.round(Math.random() * 30) + v)
.map(v => (() => taskExecutor({delay: v, index: `${idx++}` })));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment