From: John Doe Date: 2011-02-22T06:10:59+09:00 Subject: Regular expressions, strange result from .scan method Hi, I'm having some strange result from the .scan method used on a string. Here's my code : a = "counter-46382764" r = /counter-(\d+)/ puts (a.scan(r)).inspect It prints : [ [ "46382764" ] ] I was expecting : [ "46382764" ] (just a simple array not an array in an array) What's wrong with me ? :/ Thanks a lot ! pollop. -- Posted via http://www.ruby-forum.com/.