Using ‘@unknown default’ within switch statements
When switching on an enum, we are required to either explicitly handle all of its cases, or provide a default case that’ll act as a fallback for cases that weren’t matched by any previous case statement. For example like this: struct Article { enum State { case draft case published case removed } var state:…