Libraryless. Click here for Pure Java version (15125L/102K).
1 | svoid checkSuffixTreeWithRandomStrings() {
|
2 | Random random = repeatableRandomizer(); |
3 | for (int n = 100; n <= 2000000; n *= 2) {
|
4 | print(n); |
5 | S text = randomABC(n, random); |
6 | SuffixTree tree = new(text); |
7 | checkSuffixTreeSearch(tree, "abc"); |
8 | checkSuffixTreeSearch(tree, "a"); |
9 | checkSuffixTreeSearch(tree, "bac"); |
10 | } |
11 | } |
Began life as a copy of #1029208
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
| Snippet ID: | #1029218 |
| Snippet name: | checkSuffixTreeWithRandomStrings |
| Eternal ID of this version: | #1029218/3 |
| Text MD5: | 58ca3fdb55312e628a7a87ce3f31af46 |
| Transpilation MD5: | facbdbf85c3bff5cfdb8110a8dca8b48 |
| Author: | stefan |
| Category: | javax / text searching |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2020-07-25 15:09:04 |
| Source code size: | 344 bytes / 11 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 447 / 592 |
| Version history: | 2 change(s) |
| Referenced in: | [show references] |