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

14
LINES

< > BotCompany Repo | #1001074 // readLine - now prints locally with prefix

JavaX fragment (include)

1  
static volatile bool readLine_noReadLine;
2  
3  
sS readLine_lastInput;
4  
sS readLine_prefix = "[] ";
5  
6  
static String readLine() {
7  
  if (readLine_noReadLine) null;
8  
  S s = readLineHidden();
9  
  if (s != null) {
10  
    readLine_lastInput = s;
11  
    print(readLine_prefix + s);
12  
  }
13  
  ret s;
14  
}

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1001074
Snippet name: readLine - now prints locally with prefix
Eternal ID of this version: #1001074/5
Text MD5: 818059c5e7e438f3ce66bfad07542788
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-03-06 21:58:42
Source code size: 287 bytes / 14 lines
Pitched / IR pitched: No / No
Views / Downloads: 835 / 6674
Version history: 4 change(s)
Referenced in: [show references]