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

17
LINES

< > BotCompany Repo | #1009156 // joinWithComma - join with ", " separator

JavaX fragment (include)

1  
static <A> S joinWithComma(Collection<A> c) {
2  
  ret join(", ", c);
3  
}
4  
5  
sS joinWithComma(O... c) {
6  
  ret join(", ", c);
7  
}
8  
9  
sS joinWithComma(S... c) {
10  
  ret join(", ", c);
11  
}
12  
13  
ifclass Pair
14  
sS joinWithComma(Pair p) {
15  
  ret p == null ? "" : joinWithComma(str(p.a), str(p.b));
16  
}
17  
endif

Author comment

Began life as a copy of #1008249

download  show line numbers  debug dex  old transpilations   

Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1009156
Snippet name: joinWithComma - join with ", " separator
Eternal ID of this version: #1009156/5
Text MD5: 4dbda431bc4b566eeeea3f5be0dace5a
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-10-15 17:03:48
Source code size: 293 bytes / 17 lines
Pitched / IR pitched: No / No
Views / Downloads: 489 / 770
Version history: 4 change(s)
Referenced in: [show references]