Level 10 : What does this output?


lst = [1, 2, 3, 4]
lst[1:3] = [7]
print(lst)

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