From: gabe gabriellini Date: 2012-04-01T04:17:28+09:00 Subject: regexp replace every other one When i have a string like: puts "Mike Lan move the string abc def".gsub(/(\A|\s)(.{3})($|\s)/," new_value ") it only replaces two same as the next one only replaces every other one what a im missing?? puts "gta gtb gtc gxd gte".gsub(/(\A|\s)(.{3})($|\s)/," new_value ") thank you -- Posted via http://www.ruby-forum.com/.