module Bencoding module Array def to_bencoding return '' if empty? "l"+collect{|item|item.to_bencoding}.join+"e" end end end