lib/timely/week_days.rb
def weekdays_int
      int = 0
      WEEKDAY_KEYS.each.with_index do |day, index|
        int += 2 ** index if @weekdays[day]
      end
      int
    end
def weekdays_int
      int = 0
      WEEKDAY_KEYS.each.with_index do |day, index|
        int += 2 ** index if @weekdays[day]
      end
      int
    end
def weekdays_int int = 0 WEEKDAY_KEYS . each . with_index do | day , index | int += 2 ** index if @weekdays [ day ] end int end
7 bits encoded in decimal number
 0th bit = Sunday, 6th bit = Saturday
 Value of 127 => all days are on
7 bits encoded in decimal number 0th bit = Sunday 6th bit = Saturday Value of 127 = > all days are on