Skip to content
instance method

Time#sunday?

() -> bool
sunday? → true or false

Returns true if self represents a Sunday, false otherwise:

Example
t = Time.utc(2000, 1, 2) # => 2000-01-02 00:00:00 UTC
t.sunday?                # => true

Related: Time#monday?, Time#tuesday?, Time#wednesday?.

See also #subsec #thursday? #strftime #to_a also in 4.1 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0