Level 1 : What is the output of the below python code?


import socket 
ip = socket.gethostbyname('www.google.com')
print(ip)

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