Libraryless. Click here for Pure Java version (3256L/21K).
1 | svoid test_LongTreeSet() { |
2 | L<Long> list = repF(1000, () -> randomLong()); |
3 | Set<Long> set = asTreeSet(list); |
4 | LongTreeSet cset = new(set); |
5 | print(set); |
6 | print(cset); |
7 | assertEquals(asList(set), asList(cset)); |
8 | assertEqualsVerbose(l(set), cset.size()); |
9 | |
10 | for (Long a : shuffledIterator(list)) { |
11 | set.remove(a); |
12 | cset.remove(a); |
13 | assertEquals(asList(set), asList(cset)); |
14 | assertEqualsVerbose(l(set), cset.size()); |
15 | } |
16 | } |
Began life as a copy of #1029167
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1030400 |
Snippet name: | test_LongTreeSet (OK) |
Eternal ID of this version: | #1030400/3 |
Text MD5: | f5779303712f151c06ba9cd88f0479e2 |
Transpilation MD5: | d52f40fb1e874bf794336ea19d9e0dbf |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-12-13 02:07:05 |
Source code size: | 453 bytes / 16 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 222 / 325 |
Version history: | 2 change(s) |
Referenced in: | [show references] |