4 ms·
> Programming languages have to be developed from scratch to fit to other spoken languages and cultures in my opinion. This is really interesting. I wonder if
by filleokus 7y ago
> Programming languages have to be developed from scratch to fit to other spoken languages and cultures in my opinion.
This is really interesting. I wonder if there are some human language with properties that would allow for programming language constructs that we don't really use today.
My linguistic skills are not good enough to really suggest an example, but considering there is a language[0] (almost) without relative directions (left and right), which is mind blowing to me, it feels like there should be something interesting out there.
[0]: https://en.wikipedia.org/wiki/Guugu_Yimithirr_language https://en.wikipedia.org/wiki/Guugu_Yimithirr_language
- lifthrasiir 7y agoAs a very superficial example, Korean is agglutinative and you can't easily take affixes apart from a word. For example, you can't easily recognize that the following sentence has a noun "언어" and a verb stem "배우-" without a substantial knowledge about Korean: 언어를 배운다. [topic omitted] Language-(object marker "를") learn-(verb conjugation "ㄴ다"). (One) learns a language. Many syntaxes are based on easily segmented tokens, or words, so they are not a good fit for Korean and other agglutinative languages. My friend has made a programming language, Yaksok [1], specially made for Korean and solving this problem by making all invocations as a pattern, somewhat similarly to AppleScript: # - "약속" is a keyword for procedure declarations. # - Unquoted words are formal parameters. # - Anything quoted should occur literally, except for slashed alternations # used for affixes varying by the preceding word. 약속 대상"을/를 배운다" ... Of course this results in a very unconventional parser. [1] http://yaksok.org/ http://yaksok.org/
- gwd 7y ago> This is really interesting. I wonder if there are some human language with properties that would allow for programming language constructs that we don't really use today. Ooh, just thought of something interesting: I lived in Turkey for 4 months, and in Turkish, rather than using location to indicate which words modify each other, you use suffixes. (At least, as much as I could figure out in that time.) Then you can order your words for clarity and emphasis, rather than for meaning. You could imagine doing the same thing with functions or expressions; rather than being stuck with "infix" operators, which need precedence and parentheses, or "prefix" operators forcing you to use RPN, you could order them the way you want. So perhaps the following three expressions could all evaluate to the same thing ("a / b" in most C-based languages): /' a' b" /' b" a' b" /' a' a' /' b" a' b" /' The idea would be that `/` is the verb, and `'` is the suffix indicating that its two "arguments" are `'` and `"`. That sounds like an interesting concept to explore anyway.
- azernik 7y agoThere are a lot of languages like this - this is the much-studied spectrum of analytic vs. synthetic. English is one of the most strongly analytic languages (Chinese being even more extreme) - it determines word relationships and function with word order and helper words. Whereas Standard Arabic, Ancient Latin, and Finnish are very synthetic, changing words to indicate their function and relationship to other words in the sentence. If your language has the concept of "declensions", it's probably on the synthetic end of the spectrum. Interestingly, after observing an increase in analyticity over time in European languages, some linguists have hypothesized that analytic languages are easier for foreign speakers to learn as adults, and that this causes languages with lots of geographic spread and inter-language contact to become more and more analytic. With creole languages being of course the most striking example.
- gwd 7y ago> some linguists have hypothesized that analytic languages are easier for foreign speakers to learn as adults, and that this causes languages with lots of geographic spread and inter-language contact to become more and more analytic. That's an interesting theory, and certainly fits with Mandarin (aka "Common Speech"); but how well does it fit with the prevalence of Greek in the ancient world, Latin during the Middle Ages, and Arabic in the Middle East and North Africa now? Those are all towards the "synthetic" scale, aren't they? Did/have those languages drift/ed to become more "analytic"?
- housecarpenter 7y agoYeah, Latin and Greek became somewhat more analytic during the time periods where a lot of foreign speakers were adopting them as their main languages. (That was during the Roman period, not the Middle Ages, for Latin; Latin in the Middle Ages was a dead language used only by learned people in non-everyday contexts, so its grammar was mostly preserved.) I don't know about Arabic.
- azernik 7y ago