← Practice
Async·hard 30 min 120 XP

Parallel Fetching

Write fetchParallel(ids, fetcher) that starts every fetcher(id) call concurrently and returns results in the original id order.

Examples

  • fetchParallel([1,2], fetcher) starts both fetcher calls immediately

Constraints

  • Keep the required function name so the tests can find it
  • Return a value instead of only logging it
  • Do not mutate inputs unless the challenge asks you to
Parallel Fetching · editor

Code runs in an isolated Web Worker with a 3-second timeout — no DOM access, and it can never hang the page.