Level 5 : Guess the output of the following code.


list = ['apple', 'banana', 'orange']
string = ', '.join(list)
print(string)
print(type(string))

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