Hi friends, we will draw a flag with the python on this issue.
The Turkish flag.
Flag of Azerbaijan.
Subject owner: @'CaptainKanka
the original topic: https://www.turkhackteam.org/konular/phyton-ile-azerbaycan-bayragi-turk-bayragi-cizimi.2011327/
The Turkish flag.
Python:
import turtle
t = turtle.Turtle()
w = turtle.Screen()
w.title("Turkhackteam.org")
w.setup(width=720,height=420)
w.bgcolor("red")
t.up()
t.goto(-100,-100)
t.color('white')
t.begin_fill()
t.circle(120)
t.end_fill()
t.goto(-70,-80)
t.color('red')
t.begin_fill()
t.circle(100)
t.end_fill()
t.goto(0,35)
t.fillcolor("white")
t.begin_fill()
for i in range(5):
t.forward(150)
t.right(144)
t.end_fill()
t.goto(-130,-190)
t.color("white")
t.write("Turkhackteam.org", font=("Verdana", 17,"bold"))
t.goto(-999,-0)
w.exitonclick()
Flag of Azerbaijan.
Python:
import turtle
arrow = turtle.Turtle()
def star(x, y, color, length):
arrow.up()
arrow.goto(x, y)
arrow. setheading(157)
arrow.pendown()
arrow.begin_fill()
arrow.color(color)
for star in range(0, 8):
arrow.pensize(3)
arrow.forward(length)
arrow.right(135)
arrow.end_fill()
def greensqr():
arrow.pendown()
arrow.color('#509e2f')
arrow.begin_fill()
arrow.forward(500)
arrow.right(90)
arrow.forward(100)
arrow.right(90)
arrow.forward(500)
arrow.right(90)
arrow.end_fill()
arrow.penup()
def bluesqr():
arrow.pendown()
arrow.color('#00b5e2')
arrow.begin_fill()
arrow.forward(300)
arrow.right(90)
arrow.forward(500)
arrow.right(90)
arrow.forward(100)
arrow.right(90)
arrow.forward(500)
arrow.end_fill()
arrow.penup()
def redsqr():
arrow.pendown()
arrow.color('#ef3340')
arrow.begin_fill()
arrow.left(90)
arrow.forward(100)
arrow.left(90)
arrow.forward(500)
arrow.left(90)
arrow.forward(100)
arrow.end_fill()
arrow.penup()
def drawmoon(x, y, color, radius):
arrow.penup()
arrow.goto(x, y)
arrow.color(color)
arrow.begin_fill()
arrow.circle(radius)
arrow.end_fill()
def text():
arrow.penup()
arrow.goto(-565,150)
arrow.color("Dark green")
arrow.begin_fill()
arrow.goto(-565,100)
arrow.write(('Türkiye & Azerbaycan'), move=False, align="Left", font=("Flux Regular", 19, "normal"))
arrow.goto(-565,50)
arrow.write(('İki devlet bir millet'), move=False, align="Left", font=("Flux Regular", 19, "normal"))
arrow.end_fill()
def text1():
arrow.goto(-7,200)
arrow.write(('Azerbaycan'), move=False, align="Left", font=("Flux Regular", 19, "normal"))
arrow.goto(25,-270)
arrow.write((""" Turkhackteam.org"""), move=False, align="Left", font=("Flux Regular", 14, "normal"))
for i in range(1):
greensqr()
bluesqr()
redsqr()
drawmoon(280, 52, "white", 44)
drawmoon(282, 52, '#ef3340', 36)
star(297, 33, "white", 40)
text()
text1()
turtle.done()
Subject owner: @'CaptainKanka
the original topic: https://www.turkhackteam.org/konular/phyton-ile-azerbaycan-bayragi-turk-bayragi-cizimi.2011327/