CoolFace
Datasetpublic

basant307/AI_Governance_Project

sourceHugging Faceapache-2.0updated 2mo agoView on Hugging Face
0likes48downloads
iterator.js15 linesDownload Raw Back to hierarchy
1export default function*() {2  var node = this, current, next = [node], children, i, n;3  do {4    current = next.reverse(), next = [];5    while (node = current.pop()) {6      yield node;7      if (children = node.children) {8        for (i = 0, n = children.length; i < n; ++i) {9          next.push(children[i]);10        }11      }12    }13  } while (next.length);14}15 
basant307/AI_Governance_Project · CoolFace