Here is the code for the same: import turtle star = turtle . Turtle () star. color ( "pink" ) star. shape ( "turtle" ) wn = turtle . Screen () wn. bgcolor ( "black" ) for i in range ( 100 ): star. forward ( 200 + 20 * i) star. stamp () star. right ( 144 ) turtle . speed ( 9 ) turtle .done() Output of the above code:
turtle.stamp() turtle.stamp() is used to stamp a copy of the turtle shape, it prints the shape at that point and moves forward with the instructions. Here shape of the turtle does not matter. It does the same for every turtle shape. Example: Here is the example of stamp() used: import turtle def tri (): for i in range ( 10 ): turtle . degrees ( 60 ) turtle . forward ( 200 + 10 * i ) turtle . stamp () turtle . right ( 200 ) turtle . speed ( 7 ) turtle . color ( "orange" ) tri () turtle . done () For more such posts, stay tuned!