For people who already know another programming language
Learn Raku the way you learned your second language.
Nobody learns a second language from zero. You read, you compare it with the one you know, you notice the words that fool you, and slowly you lose your accent. These articles teach Raku the same way, and every example runs in your browser.
0.1 + 0.2 == 0.3False0.1 + 0.2 == 0.3TrueFour kinds of articles
Each one practises a different skill, the way a language course mixes reading, vocabulary and pronunciation.
Readers
Short programs to read before you run them. Guess what each one prints, run it, then read the notes.
All 8 readersFalse friends
Code that looks the same in Python, Perl or JavaScript and in Raku, but means something else.
- + adds, even when the numbers are stringsA1
- == does not compare stringsA1
- @a[-1] is not the last elementA2
Word families
Methods and operators that are related, learned together so that you stop mixing them up.
All 5 word familiesAccents
One task written with a Python, a Perl and a C accent, and then the way a native writes it.
All 3 accentsFind your level
Six levels, as in a language course. Read at your level, and then one above it.
Coming from another language?
False friends and accents start from what you already know.
Every example runs
The programs in these articles run in your browser, on Raku++ compiled to WebAssembly. Nothing is sent to a server. Change this one and press Run.
my @cities = 'Riga', 'Leiden', 'Turin'; say @cities[*-1]; say 'Riga'.comb; say 0.1 + 0.2 == 0.3;
Raku as a Foreign Language is one part of Learn Raku. The others: A Tour of Raku, Raku Drills, Raku by example, The Raku Cookbook, Raku Behind the Docs.