Level 10 : What will be the content of s after execution?


s = {1, 2, 3}
s.add(4)
s.discard(3)

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