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

24
LINES

< > BotCompany Repo | #1010045 // Sentence to word chain [OK]

JavaX source code (desktop) [tags: use-pretranspiled] - run with: x30.jar

Download Jar. Uses 616K of libraries. Click here for Pure Java version (14311L/103K).

!7

p {
  preloadImage(CirclesAndLines.defaultBackgroundImageID = #1007402);
  drawThoughtCircle_defaultColor = CirclesAndLines.defaultLineColor = Color.black;
  botAndFocusConsole();
  setConsoleInput("Hello world");
}

answer {
  L<S> tok = codeTokens(nlTok5(s));
  if (nempty(tok)) {
    Web web = simpleWeb();
    WebNode n = null;
    for (S t : tok) {
      WebNode n2 = web.newNode(t);
      if (n != null)
        web_arrow(n, "next word", n2);
      n = n2;
    }
    showWeb(web);
    ret "Yo yo yo";
  }
}

Author comment

Began life as a copy of #1010042

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1010045
Snippet name: Sentence to word chain [OK]
Eternal ID of this version: #1010045/9
Text MD5: 357e9a643c4afa21089ce1ddd894c618
Transpilation MD5: 01afe7a6c12dad616d449bba5d3d25af
Author: stefan
Category: javax / a.i.
Type: JavaX source code (desktop)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-09-01 17:55:44
Source code size: 539 bytes / 24 lines
Pitched / IR pitched: No / No
Views / Downloads: 309 / 790
Version history: 8 change(s)
Referenced in: [show references]