Part of traveling the world as an Anglophone involves the uncomfortable realization that everyone else is better at learning your language than people like you are at learning theirs. It’s particularly obvious in the world of programming languages, where English-derived language and syntax rules the roost.
It’s always IF foo THEN bar, and never SI foo ALORS bar. It is now possible to do something akin to OS foo YNA bar though, because [Richard Hainsworth] has created y Ddraig (the Dragon), a programming language using Welsh language as syntax. (The Welsh double D, “Dd” is pronounced something like an English soft “th” as in “their”)
Under the hood it’s not an entirely new language, instead it’s a Welsh localisation of the Raku language. A localisation file is created, that can as we understand it handle bidirectional transcription between languages. The write-up goes into detail about the process.
There will inevitably be people asking what the point of a programming language for a spoken language with under a million native speakers is, so it’s worth taking a look at that head on. It’s important for Welsh education and the Welsh tech sector because a a geeky kid in a Welsh-medium school Pwllheli deserves to code just as much as an English kid in a school near Oxford, but it goes far beyond Welsh alone. There are many languages and cultures across the world where English is not widely spoken, and every single one of them has those kids like us who pick up a computer and run with it. The more of them that can learn to code, and thrive without having the extra burden of knowing English, the better. Perhaps in a couple of decades we’ll be using code from people who learned this way, without our ever knowing it.
As your scribe, this needs to be added: Mae’n ddrwg gyda fi ffrendiau Cymraeg, mae Cymraeg i yn wael iawn. Dwi’n dôd o’r Rhydychen, ni Pwllheli.
Header image: Jeff Buck, CC BY-SA 2.0.

On the one hand I agree that representation is important. On the other, the Welsh programmer can now collaborate with the subset of Welsh speakers who are also programmers, but none of the millions of people who don’t use Welsh. In my opinion it’s doing a disservice to them.
Of course, programming is not about the language, it’s about thinking. If a person can’t think then they won’t be programming in any language.
There’s probably only a couple of dozen keywords, and a handful of popular constructs to learn (IF..THEN, WHILE…, FOR…) etc. Writing English keywords, or in some cases just symbols, with native language variable names and comments is far more useful. Now a non-Anglophone can look at source code from anywhere and follow the structure.
Source: Me. I speak four languages, and program in whatever language is appropriate.
Actually, having thought about it a little more I can see it might be useful to program in Welsh, to remove the first barrier to learning, but in the long term the student should move on.
In the case of Welsh its even more silly than that, as they do all in theory anyway HAVE to learn English anyway, and in many cases sadly are rather more likely to be English language first and at home – if you are in a bilingual school and learning Welsh and English I think that is great. Would be a nice thing if all the UK kids got a taste of at least some of the UK’s languages and dialects and the history that goes with it. But when it comes to programming when you must already know English coding in Welsh is just fun/obtuse for its own sake really.
Stick to APL – problem avoided! :-D
I second that.
I recall Algol programs with French keywords.
Way back when I found some .f source files, which looked deeply weird — they weren’t Fortran, but French C (via a #include <francais.h> and macro redefinitions of every keyword).
So do I.
Can’t remember whether it was 60 and/or 68, and can’t quickly find a reference to it.
Uhm, no. Its just that they have an incentive to start learning your language at an early age and continue to do so across they’re lives while you’re learning theirs in a short period and mostly for vanity.
If they start younger they’ll be better. Learning any second language when you’re young improves your ability to learn languages later in life.
And there is only one obvious choice to learn, and you can use it everywhere you go. As an Englishman, I’m not less capable of learning languages than anybody else, but I can’t possibly learn the language of every single country/region I may pass through.
I did go to Hungary a few years after it ceased to be communist, and at the time everybody’s second language was Russian with very little English spoken (this has now changed) which was exactly the same thing – it was the obvious choice.
I remember a book describing a student who created a program for translating BASIC programs written using multiple languages, including Tagalog. Unfortunately I don’t remember the book nor can I find info about it online.
Since it uses a localization file, any programmer can load the preferred localization faile in his IDE, and the source code will appear in the choosen language. Only the comments may be left untranslated.
Back in the late 80s / early 90s, there was a Welsh translation of LOGO for the BBC Micro, which was my first experience of programming.
In fact, back in the Beeb and Acorn days, loads of educational software was available in Welsh. The education / technical deparments of councils worked with the publishers, and the Welsh-language market was a big enough fraction of the (bespoke) UK market for the publishers to bother doing so.
Come the late 90s, when schools had switched over to PCs, we were now a tiny fraction of the worldwide English-speaking market, and the Welsh-language software dried up. I used LOGO for Windows during high school, and was annoyed at having to relearn the English keywords to get anything done.
Alright, it’s lust that is.
aaaahh lush, not lust!
Being able to code in any programming language with the syntax in your human language is nice in theory, but in practice, it won’t work.
Why not? Libraries, or rather the decades of existing libraries we have and use every day. Making localizations of these many libraries is just not realistic, at least not for languages that have been in use a long time and have a rich base of existing “English” libraries.
Much more practical would be an editor that had “hover-help” “suggested translations” from English to the programmer’s native language so he could have a clue of what words like “IF” and “THEN” mean, without actually changing the code from it’s “English” version.
“Mae’n ddrwg gyda fi ffrendiau Cymraeg, mae Cymraeg i yn wael iawn. Dwi’n dôd o’r Rhydychen, ni Pwllheli.” …. dont worry, most people in Pwllheli dont speak ‘proper’ Welsh anyway – they have their own dialect.
I am not wishing to intrude into an argument between North and South Welsh dialects. I learned mine with Say Something in Welsh, and I picked their South course. I am a very bad Welsh speaker, but my halting attempts seem to be tolerated.
“It’s always IF foo THEN bar, and never SI foo ALORS bar.” That’s not strictly true. A nice way of saying completely untrue. And this is different, but you can say “OTHERWISE” instead of “ELSE” in COBOL, at least you used to could.
I see the welsh language department at Aberysthwyth uni have manufactured a translation for the English word “code” . C^od is hardly very imaginative though, no ll’s in sight.
To be fair every word thats come into being since about the mid 20th century has required a small committee of grey beards to take the English word and Welsh it up a bit, some with more imagination than others. Ambliwans being one of my favorites.
Then again it’s not just Welsh that does this, there are far more incongruent words that have snuck into other langauges because what they are describing simply didn’t exist 100 years ago and there isn’t really a translation to fall back on.
There can be nice, native translations too:
A memory stick / USB drive / flash drive is a “cof bach” (little memory).
A mobile phone / cell phone is a “ffôn lon” (road phone) or ffôn boced (pocket phone) to many, even though the official term “ffôn symudol” is a literal translation of mobile phone.
“Teledu” (television) is based on “tele” and “lledu”, the latter of which means spreading or broadcasting. I’m not too concerned whether “tele” was picked up frm the English, given that they got it from Greek in the first place.
Plus, the grey beards don’t have an official role in Welsh like they do in the Académie Française. What you will find is that various public bodies, authors and broadcasters (or even presenters live on air) will find they need to come up with a term to describe someting, and the most popular one tends to stick. The BBC invented/standardised many rugby terms when they started broadcasting commentary of rugby matches, for example.
In Perl you can say
bar if foo;
and you can also say
if (foo) then { bar; } else { frobozz; }
You can also use “unless” which is like “if not” in either of those contexts. Perl was created by a linguist who wanted the language to be expressive with different ways of being able to code the same logic. IMO that’s the opposite of what a computer language should be.