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


x=0
while x<=18:
   x = x+3
print(x)

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