Skip to main content
2 of 5
added 246 characters in body
Rod
  • 18.4k
  • 4
  • 31
  • 89

Pyth, 7 bytes

/1-6.d9

Explanation

    .d9 # Get the current day of week (0 = Monday, 6 = Sunday)
  -6    # Subtract 6 from the day
/1      # Divide 1 by the result of the previous operation
        # raising a "ZeroDivisionError" on sundays

Try it online!

Rod
  • 18.4k
  • 4
  • 31
  • 89