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


list = ["balaji", "lakshmi"]
for i in list:
        list.append(i.upper())
print(list)

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