require 'dbm' DBM.open('r') do |db| db['t'] ="W" db[23] = "F" end DBM.open('r') do |db| puts db['t'] puts db['23'] end p Dir['r.*']