Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

10
LINES

< > BotCompany Repo | #1026469 // ludicrousRepeat

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (2249L/14K).

1  
sS ludicrousRepeat(S word) {
2  
  ret ludicrousRepeat(20, word);
3  
}
4  
5  
sS ludicrousRepeat(int max, S word) {
6  
  new StringBuilder buf;
7  
  for (char c : characters(word))
8  
    buf.append(rep(c, randomIntBetween1And(max)));
9  
  ret str(buf);
10  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 8 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, whxojlpjdney, xrpafgyirdlv

No comments. add comment

Snippet ID: #1026469
Snippet name: ludicrousRepeat
Eternal ID of this version: #1026469/2
Text MD5: d157a4ec7e55c91ce681febbe01d833b
Transpilation MD5: aa6e92b6c8238f6f2f67ff46aa8d93f9
Author: stefan
Category: javax / string fun
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-01-05 03:26:25
Source code size: 239 bytes / 10 lines
Pitched / IR pitched: No / No
Views / Downloads: 168 / 271
Version history: 1 change(s)
Referenced in: [show references]