And just to be sure, with 1.8.7 ...

irb(main):001:0> RUBY_VERSION
=> "1.8.7"
irb(main):002:0> %w( a b c )
=> ["a", "b", "c"]
irb(main):003:0> %w( a b c ).kind_of?(String)
=> false
irb(main):004:0> %w( a b c ).kind_of?(Array)
=> true

On 01/03/11 17:01, Sam Duncan wrote:
> On 01/03/11 16:45, RichardOnRails wrote:
>>
>> Hey David,
>>
>> Neat code,  but I don't get it.
>>
>> %w( a b c ) yields an instance of class String.
>
> ruby-1.9.2-p0 > %w( a b c )
>  => ["a", "b", "c"]
> ruby-1.9.2-p0 > %w( a b c ).kind_of?(String)
>  => false
> ruby-1.9.2-p0 > %w( a b c ).kind_of?(Array)
>  => true
>