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


word = "Hello"
print(word[-1])

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