import { compR } from "./compr.js";
import { __iter } from "./iterator.js";
function mapIndexed(...args) {
  return __iter(mapIndexed, args) || ((rfn) => {
    const r = rfn[2];
    const fn = args[0];
    let i = args[1] || 0;
    return compR(rfn, (acc, x) => r(acc, fn(i++, x)));
  });
}
export {
  mapIndexed
};
