[REBOL] forming a string from a block but inserting a separation character Re:

2000-08-28 Thread brian . hawley
[EMAIL PROTECTED] wrote: >s: [ 9 8 7 6 5 4 3 2 1 ] > >How do I create the string "9.8.7.6.5.4.3.2.1" from it? A simple way, good for most purposes, but incorrect when the elements contain spaces: new-s: replace/all form s " " "." A faster way, and correct when the elements contain spaces:

[REBOL] forming a string from a block but inserting a separation character Re:

2000-08-28 Thread joel . neely
A function to do what you want (name inspired by plywood) is >> ply: func [s [string!] b [block!] /local r t c] [ [r: copy "" [t: copy "" [foreach c b [ [repend r [t c] [t: s [] [r [] >> ply "." [9 8 7 6 5 4 3 2 1] == "9.8.7.6.5.4.3.2.1" >> This is a c

[REBOL] forming a string from a block but inserting a separation character

2000-08-28 Thread princepawn
s: [ 9 8 7 6 5 4 3 2 1 ] How do I create the string "9.8.7.6.5.4.3.2.1" from it? I thought that reform would have a /sepchar refinement, but it didnt. Get your FREE Email and Voicemail at Lycos Communications at http://comm.lycos.com