breadthFirstSearch(neighborSelector, keySelector = e => e) {
        let seq = this;
        return Seq.fromGenerator(function*() {
            let visited = new Set();
            let schedule = seq.toArray();
            for (let i = 0; i < schedule.length; i++) {
                let e = schedule[i];
                let k = keySelector(e);
                if (visited.has(k)) {
                    continue;
                }
                visited.add(k);
                for (let neighbor of neighborSelector(e)) {
                    schedule.push(neighbor);
                }
                yield e;
            }
        });
    }
Iterates elements reachable by starting from the given sequence and applying the given neighbor yielding function
to known nodes.
@param {!function(T) : !(T[])} neighborSelector
@param {!function(T) : K} keySelector
@returns {!Seq.<T>}
@template T, K