Warning: file_get_contents(http://localhost:8000/calc?cmd=138&userid=0&debug=1): failed to open stream: Cannot assign requested address in /var/www/tb/show-snippet.php on line 158
String split function (test) [138]

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

7
LINES

< > BotCompany Repo | #138 // String split function (test)

Lua code - System test

go("#137") -- split
go("#121") -- compare tables

assert(compareTables(split("1:23", ":"), {"1","23"}))
  
print "split works."
return true

test run  test run with input  download  show line numbers   

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

Comments [hide]

ID Author/Program Comment Date
725 #1000610 Edit suggestion:
!636
!629

main {
static Object androidContext;
static String programID;

public static void main(String[] args) throws Exception {
go("#137") -- split
go("#121") -- compare tables

assert(compareTables(split("1:23", ":"), {"1","23"}))

print "split works."
return true
}}
2015-08-19 11:53:27  delete 
723 #1000604 (pitcher) 2015-08-18 00:07:22

add comment

Image recognition results

Recognizer Recognition Result Visualize Recalc
#308 145 [visualize]

Snippet ID: #138
Snippet name: String split function (test)
Eternal ID of this version: #138/1
Text MD5: 23a0406a592a52051f27b76e69eb7d67
Author: stefan
Category:
Type: Lua code - System test
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2014-01-12 17:19:46
Source code size: 145 bytes / 7 lines
Pitched / IR pitched: No / Yes
Views / Downloads: 1280 / 201
Referenced in: [show references]