Download Jar. Libraryless. Click here for Pure Java version (1996L/14K).
1 | !7 |
2 | |
3 | p { |
4 | new Map<Int, S> m; |
5 | for (int n = 0; n <= 1024; n++) { |
6 | if (n != 0) m.put(n*10, str(n*10)); |
7 | print("n=" + n); assertEquals(n, l(m)); |
8 | ArrayTreeMap<Int, S> map = new ArrayTreeMap(m); |
9 | if (n <= 64) { |
10 | printStruct(map); |
11 | print("first=" + map.first()); |
12 | } |
13 | assertEquals(n, l(map)); |
14 | for (int i : keys(m)) { |
15 | assertEquals(str(i), map.get(i)); |
16 | assertNull(map.get(i-1)); |
17 | assertNull(map.get(i+1)); |
18 | } |
19 | assertEquals(sorted(keys(m)), asList(keys(map))); |
20 | } |
21 | print("OK"); |
22 | } |
Began life as a copy of #1011276
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, onxytkatvevr, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1011278 |
Snippet name: | Test ArrayTreeMap [OK] |
Eternal ID of this version: | #1011278/9 |
Text MD5: | c0e49e4138be9acdef945532c6dd6dbe |
Transpilation MD5: | a3f5a61916c5c4dfcd39731335fcc457 |
Author: | stefan |
Category: | javax |
Type: | JavaX source code (desktop) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-10-22 02:14:09 |
Source code size: | 549 bytes / 22 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 548 / 1107 |
Version history: | 8 change(s) |
Referenced in: | [show references] |