Syntax Matters.

(at least for beginners)

Japanese Lisp language as another door to understand computation

(First of all, please help me improve it! It’s still a baby language.)


I want you to understand that there’s a frustration for ESL (English as a Second Language) people when learning programming.
And I encourage anyone who had a joy of reading amazing books/materials in English regarding programming or even anything related to STEM (Science, Technology, Engineering, Mathematics) to try to explain them in your native language. It might help those once discouraged to learn the field, because you will open another door for learning the subject.

Programming is a subset of English

To give you a background, currently I’m learning at this wonderful place called Recurse Center. This is a place where you can focus your intellectual curiosity to pursue whatever it takes to become a better programmer.

During my time here, I have encountered countless excitement in the field of programming. I’ve been a software engineer for quite some time, but I haven’t experienced this joy for a long time.

So, what am I enjoying so much? Well, of course there are wider variety of books I can choose from in English (Just to name a few: The Little Schemer, From Mathematics to Generic Programming, Algorithms: A Creative Approach) and Recurse Center gave me an opportunity to go through them. But another thing I noticed was that explanations in English and code examples seamlessly fit together, making it easier to grasp concepts. In another word, I don’t need an extra part of my brain translating all the code to match its explanation (and vice versa), as I would in Japanese.

After all, I believe programming languages look like a subset of English (If/Else, While loop, Define/Function…).

So many things are untranslatable into Japanese

To make things worse, almost any word in programming is borrowed from English and used in Japanese. I can give you some examples of this ‘borrowing’ in so-called Katakana. We use Katakana when creating phonically equivalent word for imported concepts.

Word, Katakana in Japanese, Pronunciation in Alphabet
Internet, インターネット, Innta-netto
Computer, コンピュータ, Conpyu-ta-
Program, プログラム, Puroguramu
Compiler, コンパイラ, Konpaila
Operating System, オペレーティングシステム, Opere-tingu Sisutemu
Network, ネットワーク, Nettowa-ku
Software, ソフトウエア, Sofutowea

Do you get the idea? When I read these Katakana words in Japanese programming books, I unconsciously use a part of my brain memory in the background, translating them into English words.

This problems is beginner-specific

I’m not saying we should invent Japanese original terms in the field of programming. Having used those Katakana for so many years, it’s unpractical to do so. Moreover, I believe it’s not necessary.

I say it’s unnecessary because when it comes to a certain level of understanding, your thinking will become abstract enough that it doesn’t matter in what natural language you’re communicating. Once you reached proficiency, you are able to follow discussions within the field, because you’ve thought about it in your own way in the past.

However, there’s this one segment who’s left out. That’s a category of beginners who just started learning about the subject.
Some people have the good fortune of meeting good teachers or educational materials in your native language. But since English is becoming more and more an universal tool, it’s more likely that you’ll get a better chance of finding them if you’re fluent in English.

It’s really unfortunate that beginners suffer the most for having English as the barrier of learning programming. This extra burden is on them before they reach the joy in its field.

When you start learning, you use your native language to grasp the important concepts. Then when you’re used to its way of thinking, you’re off to its domain language, and you can abstract of what language you use to communicate.

I give you an example of programming language Ruby and its creator, Matumoto Yukihiro (AKA Matz) to tell you this is a beginner-specific issue. Matz is far more fluent in Japanese than in English, but he’s also super fluent in programming languages in general (he must have had his unique way of learning the subject!), so he succeeded in creating Ruby syntax which became universal (at least wide enough for DHH to come up with Rails).

Not so many people can follow Matz’s path, and I started thinking “What can there be to remove this English barrier for beginners?”.

My solution:

Create a programming language for his/her native language, just enough for beginners to go through the few difficult parts in its domain.

To test out if I can create another door of introductory programming material, I created a Japalisp, scheme-like programming language which aims to help you ‘have fun’ with the beauty of computation.

My intention is to create a syntax as close as possible to natural spoken Japanese. For anybody who understands Japanese, here’s a sample function which does factorial computation based on a input number.

Probably many of you don’t understand Japanese, so I included translated pseudocode, leaving the variables untranslated.

(And don’t get discouraged here even if your know nothing about Japanese. You might enjoy this language more than others, because it can work as “Japanese Language 101 for programmers”. Take a look at what its tokenizer (scanner) is doing. It chops Japanese sentences into meaningful tokens for computers. So you can use your programming knowledge to understand how a Japanese sentence is structured.)

I also gave a talk about this aspect at Recurse Center. presentation slides here.

Nonetheless, my primary intention is to provide another tool for those whose mother tongue is Japanese. So I’ve created a REPL (playground) of the language and a sample tutorial.

If you take a look at just the interpreter part of this language, you can see it’s just a subset of Scheme interpreter that I’ve made thanks to this excellent blog post. But I believe changing the whole Lisp syntax to natural Japanese expression will help it to welcome Japanese learners (especially for those who never thought about learning programming in the past).

Bring the joy of programming into your native language.

When you get the idea at certain level, you won’t need such an esoteric language like this. After all, programming language is an independent language from any natural language, specially further down the road.

Still, my frustration made me discover there are portion of population who might benefit from this experiment.

Having done this, I believe more and more people should keep looking for their own convenient way of understanding abstract things, especially in Computer Science, or even in any field of STEM (Science, Technology, Engineering, Mathematics). If you used to write your math calculation in weird way no one else understood, that’s what I’m talking about.

Let your language light your way.

(Many thanks to Mary, Bradley, Gonçalo, who’s read the post and gave feedbacks!)

Like what you read? Give Okazaki Miyama Yuta a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.