code: func ParMapN(f, xs interface{}, n int) interface{} {
  	chk := ty.Check(
  		new(func(func(ty.A) ty.B, []ty.A) []ty.B),
  		f, xs)
  	vf, vxs, tys := chk.Args[0], chk.Args[1], chk.Returns[0]
  
  	xsLen := vxs.Len()
  	ys := reflect.MakeSlice(tys, xsLen, xsLen)
  
  	if n < 1 {
  		n = 1
  	}
  	work := make(chan int, n)
  	wg := new(sync.WaitGroup)
  	for i := 0; i < n; i++ {
  		wg.Add(1)
  		go func() {
  			for j := range work {
  				// Good golly miss molly. Is `reflect.Value.Index`
  				// safe to access/set from multiple goroutines?
  				// XXX: If not, we'll need an extra wave of allocation to
  				// use real slices of `reflect.Value`.
  				ys.Index(j).Set(call1(vf, vxs.Index(j)))
  			}
  			wg.Done()
  		}()
  	}
  	for i := 0; i < xsLen; i++ {
  		work <- i
  	}
  	close(work)
  	wg.Wait()
  	return ys.Interface()
  }
docs: // ParMapN has a parametric type:
  //
  //	func ParMapN(f func(A) B, xs []A, n int) []B
  //
  // ParMapN is just like Map, except it applies `f` to each element in `xs`
  // concurrently using `n` worker goroutines.
  //
  // It is important that `f` not be a trivial operation, otherwise the overhead
  // of executing it concurrently will result in worse performance than using
  // a `Map`.