title: Ruby loop through model and assign a date
body: <p>I'm new to Ruby and trying to write a script which has</p>
  <pre><code>Departure (date, price, accommodation_start, accommodation_end)
  Accommodation (name, price, location)
  </code></pre>
  <p>Where Departure has many Accommodations</p>
  <p>Task to loop through every departures, if it is departs after 01/July/2000, assign accommodation start and accommodation end to it</p>
  <p>Here's the code I have managed to write so far</p>
  <pre><code>class Departure
    attr_reader :date, :price, :accommodation_start, :accommodation_end
  
    def initialize()
      @departure = []
    end
  end
  
  class Accommodation
    attr_reader :name, :price, :location
  
    def initialize(name, price, location)
      @name = first
      @price = price
      @location= location
    end
  end
  </code></pre>