Frontend Development 6 min read

Drawing the “What is Peiqi” Character with Python Turtle

This tutorial demonstrates how to use Python's turtle graphics library to programmatically draw the popular “What is Peaqi” character that went viral on social media, providing the complete source code, execution result image, and a brief call‑to‑action for sharing.

Test Development Learning Exchange
Test Development Learning Exchange
Test Development Learning Exchange
Drawing the “What is Peiqi” Character with Python Turtle

The article shows how to create the “What is Peaqi” cartoon character—featured in a recent movie advertisement that sparked a wave of social‑media posts—using Python's turtle module. It explains the drawing steps and provides a ready‑to‑run script.

#!/usr/bin/env python2 # coding=utf-8 import turtle as t t.pensize(4) t.hideturtle() t.colormode(255) t.color((255, 155, 192), "pink") t.setup(840, 500) t.speed(10) # 鼻子 t.pu() t.goto(-100, 100) t.pd() t.seth(-30) t.begin_fill() a = 0.4 for i in range(120): if 0 <= i < 30 or 60 <= i < 90: a = a + 0.08 t.lt(3) # 向左转3度 t.fd(a) # 向前走a的步长 else: a = a - 0.08 t.lt(3) t.fd(a) t.end_fill() t.pu() t.seth(90) t.fd(25) t.seth(0) t.fd(10) t.pd() t.pencolor(255, 155, 192) t.seth(10) t.begin_fill() t.circle(5) t.color(160, 82, 45) t.end_fill() # ... (remaining drawing commands for head, ears, eyes, cheeks, mouth, body, arms, legs, and tail) ...

Running the script produces the illustrated character, as shown in the accompanying screenshot, confirming that the code correctly renders the intended design.

The post concludes with a friendly request to share the QR code, follow the account, and spread the artwork.

graphicsTutorialturtledrawing
Test Development Learning Exchange
Written by

Test Development Learning Exchange

Test Development Learning Exchange

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.