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


import turtle
t=turtle.Pen()
for i in range(0,4):
	t.forward(100)
	t.left(120)

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