Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.Start your free trial
Does anyone know how to determine if the current time is between a specific start and end time of the day?
Hi. I need to write a piece of code that updates a UILabel to say whether the current time is between a specific start and end time. For example, I need to say that "We are open" if the current time is between 8am and 12pm. 12pm - 1pm "We are on lunch", and 1pm to 5pm "We are open", etc.. I cannot find any time comparison sources for Swift 3. Help!