At 02:12 PM 11/29/99 -0800, you wrote: > >Here are three more questions: > > 1. x/:i syntax can get but not set values in a block... why? Because REBOL does not permit the notation :i: Since i is a word, i: would be setting the i as a reference to some value, at the same time :i is dereferencing i and returning its value. Conflict of interests? > > > 2. y: make string! 100 creates a string of length 0... why? > rebol dictionary entry implies 100 would be length or > value... IMHO, it's a big fat bug. The same happens with blocks BTW. I just reported both as a bug. > > 3. is there any difference between a 1-dimensional array > and a block or series? > A very big one. A block is datatype. A series is - if you want - a pseudotype, i.e. there is no single datatype that is a series, however, series is a generic word for strings, blocks, lists and hashes. In contrast array is not a datatype at all. It is a function that creates blocks. Hope this helps, Elan > > >Script started on Mon Nov 29 14:07:07 1999 >l >>> x: [ "this" "is" "a" "test" ] >== ["this" "is" "a" "test"] >>> i: 3 >== 3 >>> x/:i >== "a" > >>> ; but all attempts to set x/:i seem to fail > >>> x/:i: "the" >** Syntax Error: Invalid word -- :i:. >** Where: (line 1) x/:i: "the" >>> >>> >>> ; y: make string! example from dictionary >>> >>>y: make string! 100 > >== "" > >>> length? y > > == 0 > > >; but note > >>> z: make string! "this" > == "this" > > >>> length? z > > == 4 >>> ; dictionary seemed to imply 100 would be either >>> ; length, storage allocation, or value of y >>> > > > >
