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

11
LINES

< > BotCompany Repo | #1024759 // chess_parseFENLine

JavaX fragment (include)

sS chess_parseFENLine(S s) {
  new StringBuilder buf;
  for i over s: {
    char c = s.charAt(i);
    if (isDigit(c))
      buf.append(spaces(charDiff(c, '0')));
    else
      buf.append(c);
  }
  ret str(buf);
}

Author comment

Began life as a copy of #1024758

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1024759
Snippet name: chess_parseFENLine
Eternal ID of this version: #1024759/1
Text MD5: 3a2ac6c2adb8578c624a7d9d84974f37
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-08-24 17:28:19
Source code size: 223 bytes / 11 lines
Pitched / IR pitched: No / No
Views / Downloads: 204 / 231
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)