Draw netflix logo using Python --by atharva pawar

In this tutorial, we will be learning how to draw Netflix logo using Python Turtle.


COPY code from below


 import turtle

from time import sleep # Part 1 : Initialize the module t = turtle.Turtle() t.speed(4) turtle.bgcolor("white") t.color("white") turtle.title('Netflix Logo') # Part 2 : Drawing the black background t.up() t.goto(-80, 50) t.down() t.fillcolor("black") t.begin_fill() t.forward(200) t.setheading(270) s = 360 for i in range(9): s = s - 10 t.setheading(s) t.forward(10) t.forward(180) s = 270 for i in range(9): s = s - 10 t.setheading(s) t.forward(10) t.forward(200) s = 180 for i in range(9): s = s - 10 t.setheading(s) t.forward(10) t.forward(180) s = 90 for i in range(9): s = s - 10 t.setheading(s) t.forward(10) t.forward(30) t.end_fill() # Part 3 : Drawing the N shape t.up() t.color("black") t.setheading(270) t.forward(240) t.setheading(0) t.down() t.color("red") t.fillcolor("#E50914") t.begin_fill() t.forward(30) t.setheading(90) t.forward(180) t.setheading(180) t.forward(30) t.setheading(270) t.forward(180) t.end_fill() t.setheading(0) t.up() t.forward(75) t.down() t.color("red") t.fillcolor("#E50914") t.begin_fill() t.forward(30) t.setheading(90) t.forward(180) t.setheading(180) t.forward(30) t.setheading(270) t.forward(180) t.end_fill() t.color("red") t.fillcolor("red") t.begin_fill() t.setheading(113) t.forward(195) t.setheading(0) t.forward(31) t.setheading(293) t.forward(196) t.end_fill() t.hideturtle() sleep(10)

Comments