Level 10 : what is the output of the following code?


dz = 1
while dz < 3: 
  	print(dz)
        dz += 1

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