#CODE = #B070 import turtle def draw_armenia_flag(t, height, width): colors = ["#d90012", "#0033a0", "#f2a800"] for box in range(3): t.fillcolor(colors[box]) t.color(colors[box]) t.begin_fill() for _ in range(2): t.forward(width) t.right(90) t.forward(height//3) t.right(90) t.end_fill() t.penup() t.right(90) t.forward(height//3) t.left(90) t.pendown() def draw_artsakh(t, height, width): draw_armenia_flag(t, height, width) t.penup() t.forward(width) t.right(180) t.pendown() half_width = width // 12 height_for_box = height // 9 t.color("white") t.fillcolor("white") for _ in range(5): t.begin_fill() for k in range(2): t.forward(half_width*2) t.right(90) t.forward(height_for_box) t.right(90) t.end_fill() t.forward(half_width) t.right(90) t.forward(height_for_box) t.left(90) t.right(180) for _ in range(4): t.begin_fill() for k in range(2): t.forward(half_width*2) t.left(90) t.forward(height_for_box) t.left(90) t.end_fill() t.forward(half_width) t.left(90) t.forward(height_for_box) t.right(90) if __name__ == "__main__": t = turtle.Turtle() turtle.bgcolor("black") t.setposition(-45, 200) t.color("white") t.write("Armenia Flag") draw_armenia_flag(t, 200, 400) t.penup() t.setposition(-45, -50) t.pendown() t.write("Republic of artsakh") draw_artsakh(t, 200, 400) t.hideturtle() turtle.done()