Live data from Hacker News

Show HN: Han – A Korean programming language written in Rust

github.com

61–70 of 131 posts

Re: Show HN: Han – A Korean programming language written in Rust

#61

I wonder why there are not more programming languages not only with non-English keywords, but with different grammars. For example, if X then Y and many other constructions closely follow English grammar, but when you study other languages you quickly become away of many other possible constructions.

I don't think programming languages follow English grammar or syntax closely.

If X then Y, sure. While X, do Y? Maybe. For X equals Y, X equals Z, X is incremented, do A? Hardly. Match X case Y1 Z1 case Y2 Z2? Definitely not

Native English speakers have a small leg up understanding the vocabulary, not the syntax.

Re: Show HN: Han – A Korean programming language written in Rust

#63

When I was studying Computer Science in college, I once remarked how lucky we, English speakers, are that programming languages use English nouns and verbs. A ton of my classmates were here on a student visa, and English was not their first language. I always thought that programming in English put me at an advantage on the learning curve. I also always thought it was silly when someone would quip that programming sh…

At a risk of going against the hivemind, I disagree. I self-taught programming quite early in my life, way before I had a good command of the English language. I've read books in my native language, talked on programming forums in my native language. In the end the "english" in programming languages is just a handful of keywords, and it didn't hinder me one bit that I had no idea "int" stands for "integer". Of course…

I have a similar experience, I learned English much later than my first programming languages, and picking up some keywords and basic APIs was never an issue (it was BASIC and C/C++ at the time). Maybe I would occasionally look up in a dictionary what is 'needle' and 'haystack' in a code snippet, and I was puzzled by the ubiquitous "foo, bar, baz", which to my relief turned out to be equally cryptic for the native speakers. I still don't feel about code as a kind of English prose, it occupies a separate part of my brain, compared to the natural languages.

Re: Show HN: Han – A Korean programming language written in Rust

#65
Great work :) If you're interested in Korean programming languages, there's a functional one called 'Nuri': https://github.com/suhdonghwi/nuri/

Rather than just translating keywords, it lets you write code that actually uses Korean grammar. For example, "10을 5로 나누고 출력하다" (literally "10 by 5 divide and print") outputs "2".

You might already know this, but there's also a Korean programming language called 'Yaksok'. Here's a 2048 written entirely in Korean: https://github.com/yaksok/yaksok/blob/master/code_examples/2...

Re: Show HN: Han – A Korean programming language written in Rust

#66

A simple translation of keywords seems straightforward, I wonder why it's not standard. # def two_sum(arr: list[int], target: int) -> list[int]: 펀크 투섬(아래이: 목록[정수], 타개트: 정수) -> 목록[정수]: # n = len(arr) ㄴ = 길이(아래이) # start, end = 0, n - 1 시작, 끝 = 0, ㄴ - 1 # while start Code would be more compact, allowing things like more descriptive keywords e.g. AbstractVerifiedIdentityAccountFactory vs 실명인증계정생성, but we'd lose out on t…

I can't speak to Korean, but thinking about Japanese, one probable reason it wouldn't catch on is how tedious and inefficient it would be to constantly switch between input modes. Japanese input mode is designed for prose, and isn't well-suited to efficiently entering the symbols commonly used in programming. Even spaces. It results in needing a lot of extra keystrokes.

Re: Show HN: Han – A Korean programming language written in Rust

#67
post #16

Wonderful! What a cool idea. For anyone interested, you can learn the whole of Hangul in an afternoon; it's cleverly designed to be very logical and has some handy mnemonics: https://korean.stackexchange.com/a/213

That is a deep knowledge that even Korean-natives would not know. I will add this site as a reference to Github. I am glad that I have you as a supporter!

Really? That's how it was taught to me by Korean teachers at University. Even if it isn't daily-useful bit of info, it's such a fundamental component of the written form that I would have expected it to be common knowledge.

Re: Show HN: Han – A Korean programming language written in Rust

#68
post #65

Great work :) If you're interested in Korean programming languages, there's a functional one called 'Nuri': https://github.com/suhdonghwi/nuri/ Rather than just translating keywords, it lets you write code that actually uses Korean grammar. For example, "10을 5로 나누고 출력하다" (literally "10 by 5 divide and print") outputs "2". You might already know this, but there's also a Korean programming language called 'Yaksok'. Her…

That is a fair feedback and I have known those languages which are very reasonable and fairly designed language. But I wanted to more focused on translated into rust for english speakers first, which would make bigger user for this language. Thanks for your feedback!

Re: Show HN: Han – A Korean programming language written in Rust

#69

When I was studying Computer Science in college, I once remarked how lucky we, English speakers, are that programming languages use English nouns and verbs. A ton of my classmates were here on a student visa, and English was not their first language. I always thought that programming in English put me at an advantage on the learning curve. I also always thought it was silly when someone would quip that programming sh…

At a risk of going against the hivemind, I disagree. I self-taught programming quite early in my life, way before I had a good command of the English language. I've read books in my native language, talked on programming forums in my native language. In the end the "english" in programming languages is just a handful of keywords, and it didn't hinder me one bit that I had no idea "int" stands for "integer". Of course…

I agree with your opinion and I was wonder how the Korean could be used in the world with full of Eng. Thanks for your feedback!

Re: Show HN: Han – A Korean programming language written in Rust

#70
@apt-apt-apt-apt pointed out in a separate comment that: >A simple translation of keywords seems straightforward, I wonder why it's not standard.

I replied that for Japanese at least, probably due to symbol input being too tedious. However I think it's worth mentioning a potential mitigation, and maybe even an advantage.

As a mitigation, full-width symbols could be used instead, which are typically the default in Japanese input. Japanese itself is also fixed-width so if done across the board the language itself becomes fixed-width, not just by virtue of a font selection.

As an advantage, some logical symbols, greek letters, other rare characters are easy to input in Japanese mode, and this could lend itself to a more symbol-heavy language design. I already take advantage of this myself with Δ, φ, and τ use selectively in a few projects. Symbols with easy entry may differ by OS, but here are a few other examples that could be useful:

≠, ≡, ∞, ∴, λ, θ, α, β, ・, °, ※

Post reply on HN