Level 10 : What is the result of the following code?


t = (1, 2, 3)
print(t.index(4))

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