static GazelleTree gazelle_searchTree_breadthFirst_backwards(F1<GazelleTree, Bool> pred, L<GazelleTree> nodes) { new LinkedList<GazelleTree> queue; addAllReversed(queue, nodes); while (nempty(queue)) { GazelleTree t = popFirst(queue); if (checkCondition(pred, t)) ret t; if (t.isSplitNode) addAllReversed(queue, t.children); else addAll(queue, t.children); } null; }
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1021566 |
Snippet name: | gazelle_searchTree_breadthFirst_backwards |
Eternal ID of this version: | #1021566/3 |
Text MD5: | af9f308897fd187d65849fe65e9ab459 |
Author: | stefan |
Category: | javax / a.i. |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-02-18 16:34:52 |
Source code size: | 416 bytes / 13 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 386 / 378 |
Version history: | 2 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) #1030913 - BreadthFirstPathFinder - breadth-first search along virtual structure, collecting links [OK] |