1 | static L flattenList(L a) { |
2 | new L l; |
3 | for (O x : a) |
4 | if (x instanceof L) |
5 | l.addAll(flattenList((L) x)); |
6 | else |
7 | l.add(x); |
8 | ret l; |
9 | } |
Began life as a copy of #1003769
download show line numbers debug dex old transpilations
Travelled to 15 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, ekrmjmnbrukm, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1004447 |
Snippet name: | flattenList |
Eternal ID of this version: | #1004447/1 |
Text MD5: | af82ad56f96502127c6e7507181874bb |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2016-08-17 16:37:04 |
Source code size: | 158 bytes / 9 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 589 / 584 |
Referenced in: | [show references] |