I am new to code writting, have to learn Ruby (windows) so I am trying
do some experaments working with files and directories.
This code, (I thinks) creates an array called file. I can do some tricks
to test that, array.empty? and I get back false for each element. I want
to be able to select each element on at a time But all I get is numbers.
Dir.foreach(".") do |file|
The code above will list all files in the directory. I need only the
file with .mp3 extion. It would be better not to use the .foreach but
could I use?