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

8
LINES

< > BotCompany Repo | #1022841 // parseEnglishMonthName

JavaX fragment (include)

static Map<S, Int> parseEnglishMonthName_cache;

// returns 1-12 (or 0 if unknown)
static int parseEnglishMonthName(S s) {
  if (parseEnglishMonthName_cache == null)
    parseEnglishMonthName_cache = listIndexCI(englishMonthNames());
  ret or(parseEnglishMonthName_cache.get(s), -1)+1;
}

Author comment

Began life as a copy of #1022833

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1022841
Snippet name: parseEnglishMonthName
Eternal ID of this version: #1022841/3
Text MD5: a88c350bc6fc18fecf38a469e3bf71e0
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-04-10 00:26:40
Source code size: 294 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 233 / 287
Version history: 2 change(s)
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)