Skip to content

Instantly share code, notes, and snippets.

@basictomonokai
Created March 13, 2017 12:38
Show Gist options
  • Save basictomonokai/15198e30f672580658dae7abebc9da39 to your computer and use it in GitHub Desktop.
Save basictomonokai/15198e30f672580658dae7abebc9da39 to your computer and use it in GitHub Desktop.
split array (BASIC!)
xdata$=data$
outxdata$=""
split xdatawk1$[],xdata$,"@y@"
array.length lxdatawk1,xdatawk1$[]
for iii=1 to lxdatawk1
split xdatawk2$[],xdatawk1$[iii],"@x@"
array.length lxdatawk2,xdatawk2$[]
xdatawka$=replace$(xdatawk2$[1],"\n","")
xdatawkb$=replace$(xdatawk2$[2],"\n","")
xdatawkb$=replace$(xdatawkb$," ","")
xdatawkc$=replace$(xdatawk2$[3],"\n","")
xdatawkd$=replace$(xdatawk2$[4],"\n","")
outxdata$=outxdata$+xdatawka$+"@x@"
outxdata$=outxdata$+xdatawkb$+"@x@"
outxdata$=outxdata$+xdatawkc$+"@x@"
outxdata$=outxdata$+xdatawkd$+"@y@"
array.delete xdatawk2$[]
next iii
array.delete xdatawk1$[]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment