From: Ahmet Kilic Date: 2009-09-18T14:14:44+09:00 Subject: simple question: compare words I want to compare same words in a and b then, I wrote this, $ye $bu a = "ali", "bel", "del","en" b = "ali","bas","del","sx","en","sz","zen" for xa in a $ye= xa end b.each do |bx| $bu = bx if $ye == $bu puts "#{$ye} and #{$bu}" end end result: => en and en but result is only "en and en". why the last one? where is the others ali and del??? -- Posted via http://www.ruby-forum.com/.