Give girls the tools and build skills
The girls were taught some basic Python Turtle commands. They learnt to build shapes and simple pictures.
Mentorship and hints
They were given the following hint.
Let them go!
They were asked to build a heart.
Outcome
They did it! They created hearts in different ways on their own.

This Valentine’s Day, we do not just celebrate just hearts—we celebrate the strong, resilient hearts of girls who code.
Read on to find out the story behind this.
I spent the last five weeks trying something different. There’s a saying often attributed to Einstein:
You can’t keep doing things the same way and expect a different result.
What this really means is that if you want a different outcome, you have to take a new, innovative, or even unusual approach.
Last year, I began teaching Year 7 girls programming. Traditionally, they start with #Scratch, a wonderful block-based programming language that many of them had already used extensively in junior school. However, I believed that with the right mindset, a growth mindset, they could build the resilience needed to code in Python.
At first, I taught Python the way most teachers do—starting with the print() function, then moving on to input(), sequencing and selection. They followed along, but soon their interest faded. They showed little motivation to see their code through to completion.
So, what did I do?
This year I decided to try something different. I sat down, scratched my head, and observed them in other activities. I realized that perhaps if we tied coding to something visual, the girls might be more motivated to reach an end goal, complete a task, or solve a problem. That’s when I decided to introduce Python using the Turtle library—and it proved to be a turning point.
We started with sequencing, carefully placing commands in the correct order to create our first visual product: a square. Suddenly, a spark ignited in them. They wanted to know more. From there, we progressed to creating an entire picture using only Python code. Their engagement skyrocketed, and I saw their motivation and resilience grow.
They learned that a missing bracket could stall an entire program. They saw how a misplaced indent could change everything. But they kept going—because they wanted to complete the picture, even though it was written in code.
My biggest buzz came yesterday—Valentine’s Day. I decided to test their resilience, perhaps subconsciously. I gave them a piece of code to draw a semicircle filled with color and simply said: It’s Valentine’s Day. Can you create a heart with a message?
Wow, did they impress me!
Through trial and error, mathematical calculations, and sheer curiosity, they figured out how to manipulate the simple Python commands in the Turtle library they had learnt so far, to transform a semicircle into a heart. Even the students who had struggled the most with programming showed determination to reach the final outcome. I was there only to provide hints, prompts, and occasional guidance—but they got there on their own.
This experience reinforced an important lesson: With the right environment, the right mentorship, and the right tools to spark and sustain interest, we can build resilience in young people—helping them become creative problem solvers.
Why teaching girls to code matters
Coding is about more than technology—it’s about empowerment. It gives girls the confidence to face challenges head-on, the patience to work through setbacks, and the creativity to find new solutions. When we teach girls to code, we’re not just preparing them for careers in tech—we’re giving them the tools to thrive in any field.
This Valentine’s Day, let’s celebrate more than just hearts—we celebrate the strong, resilient hearts of girls who code.
