
Coding Education
What Is a String in Programming: Text Data Type

Bayu Nugraha
Children's Coding Specialist

A string is a data type that stores text — a sequence of letters, numbers, spaces, or symbols written between quotation marks. For example, "Hello", "Player1", and "kids coding" are all strings. The computer treats a string as one chain of characters, not as a number it can do math with.
How Strings Work
Each character in a string is stored in order, and the computer counts positions starting from zero. The easiest way for a child to picture it is a player's name in a game. When a child types name = "Zara" in Python, the computer keeps the letters Z, a, r, a as a single string and can show it on screen with print("Hello " + name). In Scratch, the "say [Hello]" block also works with a string — the text inside the white box is the string.
One important fact: strings and numbers are different even when they look alike. "25" with quotes is a string (text), while 25 without quotes is a number you can add up. That is why "2" + "2" gives "22", not 4.
Why It Matters for Kids
Strings are one of the first concepts a child uses when building interactive programs — from greeting a player to showing a score. Understanding strings helps kids tell text data apart from number data, an essential foundation before learning variables and user input. In Algonova's coding course, children practice using strings through simple game and story projects.
Want to try? Join a free coding class and let your child build their first program.

