sS replaceAnyPrefix(S replacement, S s, S... prefixes) { for (S prefix : prefixes) if (startsWith(s, prefix)) ret replacement + substring(s, l(prefix)); ret s; }
download show line numbers debug dex old transpilations
Travelled to 12 computer(s): bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1019461 |
Snippet name: | replaceAnyPrefix |
Eternal ID of this version: | #1019461/2 |
Text MD5: | 6f0cf9604bfce14c4cf03f8a91ba1e2b |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-11-07 01:46:04 |
Source code size: | 180 bytes / 6 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 335 / 361 |
Version history: | 1 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |