Level 1 : What will be the output of the following python code?


y = 6
z = lambda x: x * y
print z(8)

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