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


for i in 'abcd'[::-1]:
    print (i)

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