Level 10 : What will be the output of the following code snippet?


dict1 = {'first' : 'sunday', 'second' : 'monday'}
dict2 = {1: 3, 2: 4}
dict1.update(dict2)
print(dict1)

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