Level 9 : What will be the output of the below python code


['f', 't'][bool('spam')]

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