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