Level 9 : What will be the output of the following Python code snippet?


print('Ab!2'.swapcase())

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