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


print("Hello {name1} and {name2}".format(name1='foo', name2='bin'))

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