Switch
Everything on SkillVeris tagged Switch — collected across the glossary, study notes, blog, and cheat sheets.
15 resources across 2 libraries
Study Notes(11)
Conditional Logic with If and Switch
If and Switch are Power Fx's two branching functions, letting formulas return different values or take different actions depending on conditions.
Conditionals in D
Learn how D Programming handles branching logic with if-else, switch, the ternary operator, and compile-time static if.
switch Statement in C++
Master the C++ `switch` statement — matching an expression against multiple case labels, the role of break, fall-through behavior, and default.
switch vs if-else in C++
Compare C++'s `switch` statement and `if-else`/`else if` ladder to choose the right decision-making construct based on readability, speed, and flexibility.
switch Statement in C
Understand the C switch statement — syntax, fall-through, break, and default rules — with a correct example and common exam traps.
switch Statement in Java
Master Java's switch statement for multi-way branching, covering classic case-break syntax, fall-through behavior, and modern Java 14+ switch expressions.
switch Statement in JavaScript
Learn how the switch statement compares a value against multiple cases using strict equality, and why break is essential to prevent fall-through.
switch Statements in Go
Understand Go's switch statement, including implicit break, fallthrough, tagless switches, and type switches.
switch Statement in Swift
Explore Swift's powerful switch statement, which requires exhaustiveness and never falls through by default.
Match Expressions
Introduces PHP 8's match expression, its strict comparison semantics, and why it is often a safer, more concise replacement for switch.
Switch Statements and Expressions
Learn how C# branches on a value using the classic switch statement and the modern, expression-based switch introduced in C# 8, including pattern matching arms.
Interview Questions(4)
Router vs Switch: What is the Difference?
A switch connects devices within a single local network and forwards frames between them using MAC addresses, while a router connects separate networks togethe…
Hub vs Switch vs Router: What Is the Difference?
A hub is a dumb Layer 1 device that repeats every incoming signal out of all its other ports, a switch is a smart Layer 2 device that reads MAC addresses to fo…
What is a Collision Domain?
A collision domain is the set of network devices whose transmissions can collide with each other because they share the same physical medium at the same time,…
What is a Broadcast Domain?
A broadcast domain is the set of devices that all receive a broadcast frame sent by any one member of the group — every host in the same broadcast domain gets…