Generator/Exponential: Difference between revisions

m
→‎JS Functional ES6: (Minor simplification of differenceGen function)
(→‎Functional JS: Added subheading for cleaner parallel)
m (→‎JS Functional ES6: (Minor simplification of differenceGen function))
Line 1,696:
stream = zipGen(ga, gb),
sb = new Set([]);
whilelet xy = take(true)1, {stream);
while (0 const< xy.length) = take(1, stream);{
ifconst (0[x, <y] xy= Array.lengthfrom(xy[0]) {;
const [x, y] = Arraysb.fromadd(xy[0]y);
if (!sb.addhas(yx)) yield x;
xy = take(1, if (!sb.has(xstream)) yield x;
}
}
};
9,659

edits