Level 1 : What is the output of the following code?


str='Coffee';
print(str.zfill(10))

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