Live data from Hacker News

Japanese explained to programmers

lajili.com

121–130 of 416 posts

Re: Japanese explained to programmers

#121
post #83
post #79

Earlier quoted context omitted.

ChatGPT's response is full of BS. 青い魚 is あおいさかな NOT あおいう お The middle character has nothing to do with the verb to be; it's an adjective suffix. 青い魚 is literally "blue fish". It's not a full sentence.

I appreciate your call out, I would've had no idea. Is the main idea still correct? I'm curious what technique Japanese speakers use to avoid collisions like the one referenced in the article.

No, TFA was a little vague but there's no collision. The kanji for mackerel 鯖 is a standalone word/idea, whose graphical representation happens to consist of the characters for "blue" and "fish" next to each other. But virtually all kanji are constructed this way, so native readers just see the overall word without considering the parts, similarly to how you'd read the word "notable" without mistaking it for "not able".

Re: Japanese explained to programmers

#122

I have to fundamentally disagree with the premise: Japanese is probably one of the least logical languages on the planet. To wit, it combines the written complexity of Chinese with the spelling inconsistency of English. The one-to-many relationship between a given kanji and its many pronunciations makes it maddeningly difficult, even for native speakers. 生, for example, has at least nine pronunciations. The only way…

"The one-to-many relationship between a given kanji and its many pronunciations makes it maddeningly difficult"

It's actually many-to-many. I know it sounds crazy, but it's even true for English, just to a much less extent. Sometimes a single Japanese word can be written as different kanjis.

Re: Japanese explained to programmers

#123

Earlier quoted context omitted.

> In fact I'd say that English in comparison feels like a man-made language purpose built for math and technology. Do explain!

Because of its exactness. Like with words like course coarse mussel muscle altar alter idle idol very vary presents presence, etc. /s

I know you're being sarcastic, but as a Spanish native speaker I'd say English precisely excels on how well it handles ambiguity and certainty.

I also hate with passion that it's not written as it sounds (I think everyone who comes from a language with very regular pronunciation will tell you this) but I don't think this is a real issue on a daily basis.

On the other hand Spanish handles other things better. I'd say Spanish is a much better language than English to express feelings, specially anger.

Re: Japanese explained to programmers

#124
post #79
post #70

In case anyone is curious, I asked ChatGPT how Japanese refer to "fish that are blue" since "blue fish" is also the word for mackerel. Coincidentally, it's exactly how I just distinguished them in English just now. You can read ChatGPT's replies below (I manually collated the replies, leaving my prompts out): In Japanese, mackerel is written as 鯖 (さば). Blue fish" in Japanese is 青い魚 (あおいう お). The middle character in "…

ChatGPT's response is full of BS. 青い魚 is あおいさかな NOT あおいう お The middle character has nothing to do with the verb to be; it's an adjective suffix. 青い魚 is literally "blue fish". It's not a full sentence.

I think I can see the confusion about い here. Not so much う お instead of さかな though...

い adjectives are said to have a built in copula, at least in material I've read, and since な in な adjectives is from the classical Japanese copula にある, one could surmise that い is also derived from a copula. As far as I can tell that is entirely wrong, but it is the kind of thing I wondered immediately after hearing that な and だ were derived from forms of ある.

Disclaimer: very little actual understanding of Japanese.

Re: Japanese explained to programmers

#125
post #75
post #42

Honestly this feels like "programmer circle jerk" material. I love Japanese. I love it so much that I (accidentally?) moved to Japan. But it really has nothing to do with programming. It's a natural langauge with all the idiosyncrasies of natural languages. In fact I'd say that English in comparison feels like a man-made language purpose built for math and technology.

Programmers are really attracted to Japanese. It's the language with the most over-engineered tools for learning.

Well programmers tend to be into video games, and at least for a while all the best video games came out of Japan, so that helped. Between that and anime I really wanted to learn Japanese, and took two semesters of it in college.

I even worked for a Japanese game publisher for a while (in their small US office, they originally invited me in to discuss maybe publishing a game I was developing that they spotted at Microsoft's XNAFest).

Spoke some Japanese phrases that everyone in the office did while there "Ohayoo gozaimasu!(good morning, as you arrive) Tadaima!(i've returned, said when you come back to the office, like after getting food or coffee) Shitsurei shimasu.(sorry for interrupting, say before enter someone else's office) Itadakimasu!(common saying before eating lunch, which we always did together) Hai, wakarimashita.(yes, i understand) Mmm, umai.(mmm, that food is tasty) Aa, so so so.(yes, i agree) Doozo.(please, go ahead)" are some of the most common examples I can remember from over a decade ago.

I also sat in some teleconference meetings conducted in Japanese with the parent company in Japan (I was pretty quiet, mostly just tried to follow general concepts and wrote down words I heard I was curious about to look up later). Even got to the point where I started saying 'Hai' instead of yes around others for a while, out of habit.

Re: Japanese explained to programmers

#126
post #71

Earlier quoted context omitted.

English passive voice construction is inverted similar to Japanese. It's just OVS vs SVO. I've never really thought of programming languages in passive voice before, but it explains why I've increasingly written and spoken in passive voice structure even though I know it's "wrong" to do so.

I wouldn't say that programming is expressed as OVS. Function calls are VSO, e.g. `push(array, element)`. Method calls are SVO, `array.push(element)`. I speculate that this is why method-style dot-notation has become so dominant over the past few decades, because of its natural familiarity to English speakers as compared to the functional VSO style.

Programming doesn't have a definite order, it depends on language. Some examples:

  movq %rax, %rbx
  add rbx, rax
  (cons a b)
  a := b;
  b 1 a + !

Re: Japanese explained to programmers

#127

Maybe a little off-topic, but do you in general need to account for larger fonts when designing software to work with kanji og traditional Chinese? It could just be my untrained eyes, but I find it hard to see the details in many of the glyphs.

It depends a lot on the text rendering system and screen in question.

For the longest time the font rendering in Windows for example was absolutely garbage for kanji/hanzi on screens like most would be using and in that situation, and yes font size generally needed to be larger than it would be for Latin language users. While Windows technically worked for these languages it clearly wasn’t designed for them. This is somewhat fixed in newer releases.

On the other hand the text rendering on macOS has handled those characters considerably better at small sizes for the past couple of decades, which isn’t too surprising because macOS has aimed to replicate printed text with more accurate letterforms ever since OS X was released, as opposed to the pixel snapping technique used by Windows’ ClearType which only plays nice with Roman characters.

Linux/Freetype has been pretty good with Japanese/Chinese for the past decade too, ever since the improved antialiasing algorithm was added in.

HiDPI screens on smartphones, tablets, and laptops handle these characters pretty well regardless of OS because at those pixel densities, text rendering systems can usually render in adequate detail even at small sizes without doing anything special.

Re: Japanese explained to programmers

#128
The bottom line is that Politeness Levels are completely beyond your understanding, so don't even try. Just resign yourself to talking like a little girl for the rest of your life and hope to God that no one beats you up.

— So You Want To Learn Japanese http://www.stmoroky.com/links/sywtlj.htm

Re: Japanese explained to programmers

#129

I have to fundamentally disagree with the premise: Japanese is probably one of the least logical languages on the planet. To wit, it combines the written complexity of Chinese with the spelling inconsistency of English. The one-to-many relationship between a given kanji and its many pronunciations makes it maddeningly difficult, even for native speakers. 生, for example, has at least nine pronunciations. The only way…

"The one-to-many relationship between a given kanji and its many pronunciations makes it maddeningly difficult" It's actually many-to-many. I know it sounds crazy, but it's even true for English, just to a much less extent. Sometimes a single Japanese word can be written as different kanjis.

Yes, you are quite right. I got my table relationships mixed up in the heat of the moment.

Re: Japanese explained to programmers

#130
post #103

Earlier quoted context omitted.

Exactly my thoughts. While not fluent for professional settings, I live in Japan and speak enough for everyday life and I can tell that the Japanese I studied at school from first principles and more "literature-like" has nothing to do with the one used day to day, and e.g. that one has nothing to do with the one used in manga. You can do the same exercise as the author with almost all languages, the only small advan…

> [everyday Japanese] has nothing to do with the one used in manga Depends on the manga you read. There are plenty of manga revolving around everyday life, so called "slices of life" by the Western fans. I'd say they tend to use your regular everyday Japanese.

He even goes on to give an example of everyday Japanese as something nobody outside of a manga would say.
Post reply on HN