Level 1 : What is the purpose of the elif statement in Python?

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