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

7
LINES

< > BotCompany Repo | #1017858 // indexOfAnySubstring

JavaX fragment (include)

static int indexOfAnySubstring(S s, S... strings) {
  for (int i = 0; i <= l(s); i++)
    for (S b : strings)
      if (substringAtIs(s, i, b))
        ret i;
  ret -1;
}

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1017858
Snippet name: indexOfAnySubstring
Eternal ID of this version: #1017858/2
Text MD5: 9c102c3b02dd153ee13d523ff12f05b0
Author: stefan
Category: javax / eleu
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-08-18 13:04:11
Source code size: 176 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 282 / 324
Version history: 1 change(s)
Referenced in: [show references]