fixed encoding issue in count.rb