Level 9 : Does Python have a Switch or Case statement like in C?

Author: Pavan | Tags: match | 1859+ Python FAQs | Share
context-manager | list-method | namespace | max-min | while-and-for-loop | string-methods | round-function | sys-module | string-slicing | opening-files-(open()) | python_version | operator-or | min-max-function | encoding | list-comprehension | asyncio-module | list-methods-and-slicing | boolean-masking | assignment-operators | exception-handling | regular-expressions | identity-operator | sorting-and-ranking | regular-expression | counter-function | regex | __future__ | method-overloading | data-structure | list-operation | recurssion | math-copysign | complex | test-discovery | logical-operation | data-type-conversions | built-in-function | mysql | raise | multiple-inheritance | string | match | data-type | list-comprehensions | parsing-with-strptime | integers | list-indexing | else-statement | loops | dictionary-comprehensions | quantifiers-(*,-+,-?,-{}) | staticmethod | oops | rollback | exponentiation | logical-operators | oop | slicing | access-modifier | bitwise-operator | strings | data-structures | operator-overloading | introduction-to-multiprocessing | multiple-inheritance | functional-programming | binary-operation | string-formatting | set-operation | anchors-(^,-$) | default-arguments | expand-tab | package-management | else | math | data_structure | list-join | choice | immutable-data-type | installation | complex-number | object-attribute | zip | iterator | why-use-multiprocessing-over-threading?-(gil) | precedence-and-associativity | dicts | bitwise | copy | built-in | touples | logical-operator | tuples | set | logical-operator | list | frozenset | call | center | data-type | return-statement | membership-operators-(in,-not-in) | comment | using-os-and-pathlib-modules | datetime | comprehension | conditional-statements | format | using-else-and-finally | virtual-environment | iterators | type_conversion | python-syntax-and-structure | binary | file-handling | datetime.date,-datetime.time,-datetime.datetime | sys | advanced-file-operations | exception-handling | difference-between-threads-and-processes | tuple-methods | string-concatenation | compute | iterable | shallow-copy | overriding-methods | aggregating-data-with-functools.reduce() | basic | postfix | constructor | method | working-with-dates-and-times | formal-and-actual-parameter | multithreading | reading-and-writing-large-files-efficiently | sorting | filter | while-loop | python | multiple-except-blocks | time-series-with-pandas | syntaxerror | global-keyword | mathematics | formatting-with-strftime | syntax-error | thread | dictionary | global-variable | nested-loop | collection | floating-point-precision | type-conversion | string-method | error-handling | booleans | update | generator | identifier | split | conditional-statement | default-mutable-argument | def | type-conversion-and-casting | typeerror | using-assertions-(assertequal,-assertraises) | name-mangling | literal-characters-and-special-characters | pass | inherit | zip-function | turtle | heap-memory | identity-operators-(is,-is-not) | built-in-function | expression | python-django | parameter | python-operators | working-with-temporary-files-using-tempfile | pseudocode | recursion | version-check | introduction-to-python | stack | static-method | benefit | list-vs-tuple | variable | control-flow | boolean | debugging | key-value-pairs | function-argument | raise-statement | python-module | lambda-function | slice | higher-order-function | dataframe-and-series-objects | file_handling | mathematical-function | filter-function | control-statement | loop-control | inheritance | introduction-to-threads | directory-operations | asyncio | with-statement | application | operator | version | indexing | matplotlib | exception | polymorphism | fabs-function | id-function | arithmetic-operation | implementation | class | immutability | append | class-and-object | sum() | random | python-history | module | deep-copy | control-flow | reading-and-writing-files | list-mutation | function-and-scope | tuple-unpacking | identity-operator | encapsulation | condition | memory | reading:-read(),-readline(),-readlines() | assignment-operator | loop | class-and-instance-variable | using-join()-and-is_alive()-methods | head-and-tail | input | handling-missing-values-(fillna,-dropna) | matrix-list-comprehension | working-with-file-paths | sum-function | enumerate() | print | descriptors | array | decimal | destructor | join | interpreter | generators-in-python | input-function | comparison | mapping-function | swapping | yield | string-iteration | map-function | statement | lambda | round | numeric | string-formatting | print-statement | class-decorators | function | __all__-attribute | lambda-functions | lambdas | thread-synchronization | conditional-statement | dictionaries | list-slicing | operators | creating-and-starting-threads | decorator | loop-control-statements | floats | single-inheritance | methods | error | __init_subclass__ | precedence | zfill-function | syntax | pandas | multiprocessing | while-else-loop | using-lists-as-stacks | integer | conversion | intering | attribute | design-principle | factorial-function | int | objects | docstring | walking-through-directories-using-os.walk() | unit-testing | global-variable | numpy | sorted | odd-number | goto-function | software-design | indexing:-loc-vs-iloc | tuple | mutable | min-function | boolean-and-non-boolean | init | collections | data-structures-in-python | pickling--unpickling | joining-and-merging-dataframes | keyword | sets | operator-and | virtual-environment | operand | error-handling | random-function | while-loops | data-structure | threading | filtering-and-indexing | thread-safe-data-structures-(queue.queue) | import-method | lists | scientific-notation | gil | counter | library | input-function | list,-set,-and-dictionary-comprehensions | arithmetic-expression | global | using-yield-in-functions | creating-custom-modules | invalid-list | operations | indentation | for | string-method | overflow | memory-management | bitwise-operator | working-with-binary-files-(rb,-wb) | file | defining-functions | range | namedtuple | built-in-modules | escape-operator | string-slicing | pep | arbitrary-arguments-(*args,-**kwargs) | class-and-inheritance | type-conversion | data-types | list-comprehension | python-repl | feature | matrix | using-map()-for-transformations | managing-directories-with-os-and-shutil | magic-method | functions | async | generators | writing:-write(),-writelines() | assert | file-handling | string-manipulation | using-the-threading-module | dictionary-methods | command-line-parsing | syntax-error | classes | functional-programming | datatype ...