main.swift141 chars10 linesThis switch statement sets the value constant to 42, and then switches over it. Since the case matches the value, it prints "Value is 42".
index.tsx235 chars13 lines
This switch statement sets the value constant to 42, and then switches over it. Since the case matches the value, it logs "Value is 42" to the console. The break statement is important to ensure that no other cases are evaluated once a matching case has been found.
gistlibby LogSnag