Level 1 : What is the output of the below code?


a=[1,2,3,4]

a.remove(2)
a.pop(1)
del a[1]

print(a)

Author: VenuEmmela | Tags: list | 1736+ Python FAQs | Share
list-comprehension | application | sys | dictionary | mutable | data_structure | operator-overloading | decimal | factorial-function | slice | string-method | sum() | touples | shallow-copy | python-repl | context-manager | global-keyword | datatype | generators | join | software-design | keyword | gil | thread | python | boolean | operations | type-conversion | math | min-max-function | control-flow | data-structures | pep | complex-number | comparison | recurssion | tuple-unpacking | postfix | __future__ | command-line-parsing | string-formatting | string-formatting | comment | input-function | syntaxerror | for | function | string-slicing | def | precedence | escape-operator | namedtuple | feature | recursion | basic | multithreading | asyncio-module | global | library | virtual-environment | regular-expression | method | random | global-variable | round | module | append | parameter | function-and-scope | string | conditional-statement | magic-method | class | while-loop | virtual-environment | syntax-error | file-handling | syntax-error | python-module | update | iterator | docstring | bitwise-operator | zip | binary | loops | zip-function | version | lambdas | memory | odd-number | map-function | bitwise | python-history | design-principle | operator-or | async | built-in-function | stack | fabs-function | __all__-attribute | dictionaries | destructor | loop-control | exception | mathematics | loop | set | nested-loop | package-management | constructor | decorator | static-method | operator-and | identifier | choice | type-conversion | file-handling | arithmetic-expression | functions | condition | iterable | global-variable | function-argument | zfill-function | string-concatenation | precedence-and-associativity | control-flow | __init_subclass__ | interpreter | classes | comprehension | yield | default-mutable-argument | identity-operator | objects | mathematical-function | math-copysign | regex | lambda | inheritance | expand-tab | data-structure | data-structure | logical-operator | tuple | return-statement | conditional-statement | statement | python-django | debugging | counter | exception-handling | copy | split | swapping | lists | heap-memory | python_version | with-statement | generators-in-python | max-min | threading | dicts | sorting | operand | turtle | input-function | list-mutation | format | int | list-vs-tuple | multiprocessing | lambda-function | numpy | string-method | methods | oop | immutable-data-type | string-slicing | frozenset | pandas | formal-and-actual-parameter | compute | asyncio | generator | logical-operation | class-and-inheritance | indexing | built-in-function | control-statement | list-indexing | string-iteration | datetime | exception-handling | namespace | integer | call | syntax | multiple-inheritance | variable | inherit | match | type_conversion | goto-function | arithmetic-operation | version-check | oops | binary-operation | import-method | data-type | floating-point-precision | scientific-notation | memory-management | sys-module | operator | while-else-loop | file | list-slicing | functional-programming | implementation | array | print | slicing | access-modifier | boolean-and-non-boolean | numeric | benefit | range | pickling-&-unpickling | expression | built-in | while-and-for-loop | set-operation | list | filter | object-attribute | typeerror | file_handling | init | staticmethod | conversion | immutability | complex | head-and-tail | assignment-operator | name-mangling | data-type | random-function | bitwise-operator | else-statement | round-function | collection | enumerate() | installation | matplotlib | list-method | sorted | class-and-object | attribute | deep-copy | logical-operator | exponentiation | descriptors | invalid-list | encapsulation | overflow | assert | print-statement | center | mapping-function | error-handling | class-and-instance-variable | filter-function | raise | string-manipulation | polymorphism | encoding | indentation | pseudocode | error | collections | mysql | input | matrix-list-comprehension | list-operation | rollback | id-function | list-join | matrix | counter-function | operators | sum-function | list-comprehension | higher-order-function | min-function | identity-operator ...