Level 1 : What will be the output of the following Python code if x=1?


x<<2

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