# Teaching Julia to Children

**URL:** <https://discourse.julialang.org/t/teaching-julia-to-children/125575>\
**Category:** Teaching & Outreach\
**Created:** [February 5, 2025, 9:50am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575 "2025-02-05T09:50:30Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![andreeco](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@andreeco](https://discourse.julialang.org/u/andreeco)\
**Post date:** [February 5, 2025, 9:50am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/1 "2025-02-05T09:50:30Z")

</div>

Hi,

I’ve learned Julia some time ago by reading its documentation multiple times. It’s amazingly well-written! However, it is tailored for people with a university background. I want to teach programming to the next generation, specifically my children. How did you, or how would you, approach this?

There are two ways I might approach this:

1. I am considering rewriting important parts of the Julia documentation in a less mathematical and more accessible style using the package Documenter.jl.

2. Writing it in a tutorial style with projects, perhaps focusing on the math and physics taught in school. For this I would also use the package Documenter.jl. While doing this, I would include many comments in the code referring to the documentation so that important parts are referenced and can be systematically updated.

Does anyone have experience with teaching a programming language to the next generation? What I want to avoid is making it seem boring for them, causing them to lose interest.

Best regards,

André

---

<div class="post-metadata">

**Author:** ![Datseris](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/datseris/32/13406_2.png) [@Datseris](https://discourse.julialang.org/u/Datseris)\
**Post date:** [February 5, 2025, 9:58am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/2 "2025-02-05T09:58:52Z")

</div>

I would do something like your 2, but avoid Documenter.jl; I would use Jupyter notebooks. Seems to me like a much more accessible medium for your target audience as it interlaces normal text with code and figures rather straightforwardly.

CU!

George

---

<div class="post-metadata">

**Author:** ![andreeco](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@andreeco](https://discourse.julialang.org/u/andreeco)\
**Post date:** [February 5, 2025, 10:11am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/3 "2025-02-05T10:11:19Z")

</div>

Using Jupyter Notebooks is a good idea. Maybe I should use Literate.

---

<div class="post-metadata">

**Author:** ![Datseris](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/datseris/32/13406_2.png) [@Datseris](https://discourse.julialang.org/u/Datseris)\
**Post date:** [February 5, 2025, 10:21am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/4 "2025-02-05T10:21:07Z")

</div>

you can draw inspiration from my Zero2Hero if you like : [GitHub - Datseris/Zero2Hero-JuliaWorkshop: Intensive Julia workshop that takes you from zero to hero](https://github.com/Datseris/Zero2Hero-JuliaWorkshop/tree/main)

this is what I use to teach BSc students with only rudimentary programming familiarity. Perhaps you can take parts and simplify more according to what you need. I’ve never taught pre-BSc humans so I can’t judge how advanced the material is…

---

<div class="post-metadata">

**Author:** ![grahamstark](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/grahamstark/32/5200_2.png) [@grahamstark](https://discourse.julialang.org/u/grahamstark)\
**Post date:** [February 5, 2025, 10:27am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/5 "2025-02-05T10:27:55Z")

</div>

There are some nice sample notebooks in [Pluto’s gallery page](https://featured.plutojl.org/). Some may be a little challenging for school students, but perhaps you could build on those.

---

<div class="post-metadata">

**Author:** ![Palli](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/palli/32/3380_2.png) [@Palli](https://discourse.julialang.org/u/Palli)\
**Post date:** [February 5, 2025, 2:03pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/6 "2025-02-05T14:03:13Z")

</div>

FYI:

> **[Tanmay Teaches Julia for Beginners: A Springboard to Machine Learning for All...](https://www.amazon.com/Tanmay-Teaches-Julia-Beginners-Springboard/dp/1260456633)**
>
> Tanmay Teaches Julia for Beginners: A Springboard to Machine Learning for All Ages \[BAKSHI\] on Amazon.com. \*FREE\* shipping on qualifying offers. Tanmay Teaches Julia for Beginners: A Springboard to Machine Learning for All Ages

and [Introducing Julia - Wikibooks, open books for an open world](https://en.wikibooks.org/wiki/Introducing_Julia)

Please feel free to update the wikibook. They probably do not want or support notebooks, but they might be ok with links to? However, while many people like notebooks, they aren’t considered good by at least one person, for the right reason(s). If I recall it had to do with Jupyter notebooks being non-reactive, and that doesn’t apply to Pluto.jl. So Pluto is better and some Jupyter Python replacement that was based of Pluto’s ideas. I don’t keep track, maybe Jupyter is reactive by now; or maybe only with some extension?

> [@andreeco](#):
>
> I want to teach programming to the next generation, specifically my children.

May I ask how old? Or how old you think you can target? The expert programmer Tanmay was only 15 year old when he wrote the book above, and it wasn’t even his first book, actually his third, had also been working for IBM etc. At least read there online publicly available “About the author” and not the forward from Dr. Viral Shah Julia’s cocreator.

---

<div class="post-metadata">

**Author:** ![tamasgal](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamasgal/32/27946_2.png) [@tamasgal](https://discourse.julialang.org/u/tamasgal)\
**Post date:** [February 5, 2025, 2:11pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/7 "2025-02-05T14:11:24Z")

</div>

I personally also would recommend Pluto.jl Jupyter adds another layer of technology and even more confusion, in my opinion and experience. Pluto.jl is just another Julia package and everything works out of the box.

---

<div class="post-metadata">

**Author:** ![tomerarnon](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tomerarnon/32/3170_2.png) [@tomerarnon](https://discourse.julialang.org/u/tomerarnon)\
**Post date:** [February 5, 2025, 11:40pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/8 "2025-02-05T23:40:26Z")

</div>

Julia is certainly my favorite language, but as a first language I always recommend Processing because of the immediacy and intuitiveness of the output!

> **[Welcome to Processing!](https://processing.org/)**
>
> Processing is a flexible software sketchbook and a language for learning how to code. Since 2001, Processing has promoted software literacy within the visual arts and visual literacy within technology…

> **[OpenProcessing - Creative Coding for the Curious Mind](https://openprocessing.org/)**
>
> OpenProcessing - Creative Coding for the Curious Mind

This Processing centered youtube channel is especially good for kids.

> **[The Coding Train](https://www.youtube.com/@TheCodingTrain/videos)**
>
> All aboard! The Coding Train is on its way with creative coding video tutorials on subjects ranging from the basics of programming languages like JavaScript to algorithmic art, machine learning, simulation, generative poetry, and more. Choo choo!

Julia would make a perfect all purpose language to learn second!

---

<div class="post-metadata">

**Author:** ![jar1](https://avatars.discourse-cdn.com/v4/letter/j/c0e974/32.png) [@jar1](https://discourse.julialang.org/u/jar1)\
**Post date:** [February 6, 2025, 1:20am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/9 "2025-02-06T01:20:13Z")

</div>

I also think Julia is a good later language. [Scratch](https://scratch.mit.edu/about) and [Hedy](https://hedy.org/) are aimed at kids. [Racket](https://racket-lang.org/#education) has a curriculum designed for age 12-13.

---

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [February 6, 2025, 9:13am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/10 "2025-02-06T09:13:09Z")

</div>

Depends on how old and how much experience they have.  
I think the key on kids is interest.

Show them how they can solve their math schoolbook problems with Julia, or how to program a simple videogame and they will love it 🙂

(especially for the “videogame” option, sratch and scratch junior are great for small kids)

---

<div class="post-metadata">

**Author:** ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Post date:** [February 6, 2025, 10:26am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/11 "2025-02-06T10:26:24Z")

</div>

> [@andreeco](#):
>
> I want to teach programming to the next generation, specifically my children. How did you, or how would you, approach this?

Depends on their age and interests.

Generally, as a first programming language, I would use the generic Algol 60 parts of Julia: here is how you define a `function`, a loop, use an array, make a `struct`, etc. Play with the REPL as a calculator. Implement simple algorithms, like the [Sieve of Eratosthenes](https://en.wikipedia.org/wiki/Sieve_of_Eratosthenes).

I would stay away from code optimality, inference, macros, packages, tooling, and anything that is just too much to digest. So, basically, you would be teaching Julia because you know Julia, not because you require anything Julia-specific.

> [@andreeco](#):
>
> rewriting important parts of the Julia documentation in a less mathematical and more accessible style using the package [Documenter.jl](https://juliaregistries.github.io/General/packages/redirect_to_repo/Documenter)

I would definitely not do that, dealing with tooling as your first encounter with programming will just sour the whole experience. Tooling is necessary, but it is not the fun part.

> [@andreeco](#):
>
> include many comments in the code referring to the documentation so that important parts are referenced and can be systematically updated

Ditto. Don’t make them write documentation.

---

<div class="post-metadata">

**Author:** ![andreeco](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@andreeco](https://discourse.julialang.org/u/andreeco)\
**Post date:** [February 6, 2025, 11:09am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/12 "2025-02-06T11:09:08Z")

</div>

Thanks a lot for the replies so far. I’m targeting the age group between 10 and 15 years.

One of the main things is that I want them to grow up feeling it’s **natural** to use a programming language. Later, they should use the documentation to dive deeper into Julia.

My children use/used Scratch first. It will also be taught in grades 5 and 6. They have so much fun seeing the results.

One big issue is that code without results can look boring.

I think a tutorial is the right way, and I have an idea that is evolving. It could be like a **“Treasure Hunt”** , where problems have to be solved using Julia. The most important thing is that psychological effects are taken into account, and they feel that they know some Julia afterwards.

A tutorial in the form of a story could have 20 chapters. In the beginning, a boy and a girl and the reader go into a library and find a mysterious book.

They are fascinated by it and want to find some kind of treasure, let’s say from the Vikings. The map to the treasure, either a text or a picture, is encrypted. (I would use a decryption algorithm in Julia.) However, they get the password step by step (in each chapter) by solving the treasure hunt. In the end, they use something like `decrypt("password", "encrypted_text")` to solve the riddle. Each chapter contains part of the story and small programming tasks that have to be solved on the way.

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [February 6, 2025, 11:26am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/13 "2025-02-06T11:26:52Z")

</div>

I remember from my early days that I found it much more exciting if the computer did something with the “real world” rather than just calculate some number or run some algorithm. Things that I’d group into that category:

- the internet (downloading/scraping something/calling some API and getting a response)
- hardware
  - display an image, a video, or an interactive visualization
  - play some sound
  - interact with some other device somehow

Playing with an arduino I had so much fun just making LEDs light up.

For example, you could show for loops and arrays by building sentences and sending a command to the computer to use the silly inbuilt computer voice, and make it sort of mad-libs style by interpolating random words from a set or dictionary into those.

(This works on my mac, other OSes might have similar commands)

```julia
animals = ["dog", "cat", "duck"]
sounds = ["woof", "meow", "quack"]
for (animal, sound) in zip(animals, sounds)
  run(`say The $animal says $sound`)
end

```

---

<div class="post-metadata">

**Author:** ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Post date:** [February 6, 2025, 11:34am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/14 "2025-02-06T11:34:36Z")

</div>

> [@andreeco](#):
>
> I think a tutorial is the right way, and I have an idea that is evolving. It could be like a **“Treasure Hunt”** , where problems have to be solved using Julia. The most important thing is that psychological effects are taken into account, and they feel that they know some Julia afterwards.

You know your own children best and should be the best person to make up an interesting problem they can solve with Julia.

That said, I am skeptical of the approach of pouring glitter on everything just to interest children. I think that the problem with Scratch is that it is full of distractions and does not achieve the purpose of getting children interested in programming _per se_, because that knowledge is hidden under so many layers of visual concepts. I have seen children who completed a Scratch “programming” course, yet have no idea what loops or branches are (though Scratch has both).

If you insist on graphical elements, and interactive play, you will be spending a lot of time on interfacing those parts. Moreover, to be honest, these are not Julia’s comparative advantage.

---

<div class="post-metadata">

**Author:** ![andreeco](https://avatars.discourse-cdn.com/v4/letter/a/d26b3c/32.png) [@andreeco](https://discourse.julialang.org/u/andreeco)\
**Post date:** [February 6, 2025, 12:27pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/15 "2025-02-06T12:27:42Z")

</div>

I also believe they should use “real” Julia, but embedding it into a story is another matter. Let me provide an example: suppose there is a riddle involving an ancient text.

```julia
ancient_text = "☥♠♣ ☧♣♥ ♦♤ ♠♣♢♣"

ancient_dict = Dict('☥' => 'T', '♠' => 'H', '♣' => 'E', '☧' => 'K', '♥' => 'Y', '♦' => 'I', '♤' => 'S', '♢' => 'R')

decoded_message = replace(ancient_text, ancient_dict...)
println("Decoded Message: ", decoded_message)

```

Among other things, this would help to explain strings, characters, and Unicode and still be interesting.

---

<div class="post-metadata">

**Author:** ![Datseris](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/datseris/32/13406_2.png) [@Datseris](https://discourse.julialang.org/u/Datseris)\
**Post date:** [February 6, 2025, 12:34pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/16 "2025-02-06T12:34:05Z")

</div>

Actually, your last post is a fantastic example for young children!!! I will absolutely steal it for when I have kids!!!

---

<div class="post-metadata">

**Author:** ![Datseris](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/datseris/32/13406_2.png) [@Datseris](https://discourse.julialang.org/u/Datseris)\
**Post date:** [February 6, 2025, 12:47pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/17 "2025-02-06T12:47:00Z")

</div>

I think a good approach to making young children appreciate programming is its “efficiency”: you make it do a task you can do but faster. This decoding example is very nice. Because you if you have only a sentence, you can do the translation yourself. But then you give your kids a whole A4 page (that has been first transcoded with Julia) and you’re like “well, we don’t have all day to decode! That’s when we can turn to a computer!!!”

---

<div class="post-metadata">

**Author:** ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Post date:** [February 6, 2025, 1:11pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/18 "2025-02-06T13:11:24Z")

</div>

> [@andreeco](#):
>
> explain strings, characters, and Unicode

The great thing about Julia’s strings (and your example) is that one does not need to bother understanding what Unicode is at an introductory level. Those are characters, and strings are made up from characters (just don’t index them, iterate instead).

The user learning programming would not need to know about Unicode and encodings at all. (Except if you want to tell them about the olden days, when we only had ASCII and various ISO encodings, and used to walk five miles to and from school, uphill both ways, etc).

---

<div class="post-metadata">

**Author:** ![StevenSiew](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stevensiew/32/218393_2.png) [@StevenSiew](https://discourse.julialang.org/u/StevenSiew)\
**Post date:** [February 7, 2025, 4:01am UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/19 "2025-02-07T04:01:22Z")

</div>

Have you consider getting them to read “Goldbug” by Eager Allen Poe and have them decrypt the treasure message?

> **[The Gold Bug by Edgar Allan Poe](https://poestories.com/read/goldbug)**
>
> The complete, unabridged text of The Gold Bug by Edgar Allan Poe, with vocabulary words and definitions.

```julia
julia> ciphertext_goldbug
"GBXXFBIGDDOLKEMNODEXHDEXDKMIOLKEMFMUOIDDMGKZXWKJXLMFMBWMMDGLFKEOWKMMLYOLTKMDLXWKEMGDKGLFNJLXWKEYGOLNWGLCEDMUMLKEIOYNMGDKDOFMDEXXKZWXYKEMIMZKMJMXZKEMFMGKEDEMGFGNMMIOLMZWXYKEMKWMMKEWXTBEKEMDEXKZOZKJZMMKXTK"

```

---

<div class="post-metadata">

**Author:** ![ericphanson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ericphanson/32/215186_2.png) [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Post date:** [February 7, 2025, 3:40pm UTC](https://discourse.julialang.org/t/teaching-julia-to-children/125575/20 "2025-02-07T15:40:40Z")

</div>

I think my first programming experience was with terrapin logo; I remember the creative/visual aspect was engaging (try to make the turtle draw something you imagine), and being able to use loops to make spirals and such helped me see the possibilities of programming (“oh I don’t need to type this 20x, I can just do a loop”).

Pluto has a similar notebook: [Turtles – introduction](https://featured.plutojl.org/basic/turtles.html)

[Next page](https://discourse.julialang.org/t/teaching-julia-to-children/125575.md?page=2)
