From: Robert Klemme Date: 2006-10-19T22:35:12+09:00 Subject: Re: iterator inside string On 19.10.2006 15:29, akbarhome wrote: > Hi, > > This is the code: > a = [ 'a', 'b' ] > b = 2 > stringbla = "home #{ a.each {|i| i * b } } work" > puts stringbla > > output: > home ab work > > How do I modifiy the iterator so the output will be: > home aabb work > > Thank you. > use #map instead of #each robert