Level 1 : What will be the output of the following Python code?


re.split(r'(a)(t)', 'Maths is a difficult subject')

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