Level 9 : what is the output of the following code?


sampleList = [10, 20, 30, 40]
del sampleList[0:6]
print(sampleList)

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