def encoding_for_bars(*bars_and_spaces)
      bar = false
      bars_and_spaces.flatten.map do |width|
        bar = !bar
        (bar ? '1' : '0') * (width == WIDE ? wide_width : narrow_width)
      end.join
    end
def encoding_for_bars(*bars_and_spaces)
      bar = false
      bars_and_spaces.flatten.map do |width|
        bar = !bar
        (bar ? '1' : '0') * (width == WIDE ? wide_width : narrow_width)
      end.join
    end
Takes an array of WIDE/NARROW values and returns the string representation for
those bars and spaces, using wide_width and narrow_width