Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Traditional Chinese version #1163

Merged
merged 65 commits into from
Apr 5, 2024
Merged

feat: Traditional Chinese version #1163

merged 65 commits into from
Apr 5, 2024

Conversation

krahets
Copy link
Owner

@krahets krahets commented Mar 22, 2024

Initially translate the SImplified Chinese version to the Traditional Chinese version.

@krahets krahets added translation English translation code Code-related documents documents-related labels Mar 22, 2024
@krahets krahets changed the title feat: Develop traditional Chinese version feat: Traditional Chinese version Mar 23, 2024
@Jules8807
Copy link

De lux

@krahets krahets changed the base branch from main to dev_s2c_ref March 24, 2024 19:36
@Shyam-Chen
Copy link
Contributor

Shyam-Chen commented Mar 25, 2024

  • class - 类 - 類別
    • constructor - 构造方法 - 建構子
  • xor (Exclusive or) - 异或 - 互斥或

  • extend
    • 扩展数组长度 -> 擴充套件陣列長度 -> 擴展陣列長度 ("扩展"可直接繁化,多了"套件"二字)

@Shyam-Chen
Copy link
Contributor

Shyam-Chen commented Mar 25, 2024

You are awesome! Would you like to release a test version first?

@krahets
Copy link
Owner Author

krahets commented Mar 25, 2024

  • class - 类 - 類別

    • constructor - 构造方法 - 建構子
  • xor (Exclusive or) - 异或 - 互斥或

  • extend

    • 扩展数组长度 -> 擴充套件陣列長度 -> 擴展陣列長度 ("扩展"可直接繁化,多了"套件"二字)

Fixed at 2291797 a105719

You are awesome! Would you like to release a test version first?

I'm not sure if the quality of the current version is up to par, so I'd like to let native Traditional Chinese speakers try it out first. When a certain number of readers agree that the quality is good, I will release them.

Let's fix the bug so that we can release them earlier.

@krahets
Copy link
Owner Author

krahets commented Mar 25, 2024

@Shyam-Chen Which one is correct?
此類別排序演算法 vs. 此類排序演算法
以此類別推 vs. 以此類推

@Shyam-Chen
Copy link
Contributor

Shyam-Chen commented Mar 25, 2024

@Shyam-Chen Which one is correct?
此類別排序演算法 vs. 此類排序演算法
以此類別推 vs. 以此類推

  • 此類排序演算法 (2)
  • 以此類推 (2)

e.g. 諸如此類

image

@krahets
Copy link
Owner Author

krahets commented Mar 26, 2024

@Shyam-Chen 是否可以理解为:“类”这个字可以直接简体转繁体,只有在特指“类(class)”时例外?

@Shyam-Chen
Copy link
Contributor

Shyam-Chen commented Mar 26, 2024

是否可以理解为:“类”这个字可以直接简体转繁体,只有在特指“类(class)”时例外?

可以,但好像又不是,用習慣了,不知道怎麼去解釋它

image

image

@krahets
Copy link
Owner Author

krahets commented Mar 26, 2024

@Shyam-Chen 看来只有在计算机科学中的“类(class)”才翻译为“類別” (这种 n - > n+1 的转换令人头大)

@Shyam-Chen
Copy link
Contributor

Shyam-Chen commented Mar 26, 2024

簡:常量、变量、对象占用 O(1) 空间
繁:常量、變數、物件佔用 O(1) 空間

  • constant - 常量 - 常數

时间复杂度

簡:

def algorithm(n: int):
    a = 2      # 1 ns
    a = a + 1  # 1 ns
    a = a * 2  # 10 ns
    # 循环 n 次
    for _ in range(n):  # 1 ns
        print(0)        # 5 ns

繁:

def algorithm(n: int):
    a = 2      # 1 ns
    a = a + 1  # 1 ns
    a = a * 2  # 10 ns
    # 迴圈 n 次
    for _ in range(n):  # 1 ns
        print(0)        # 5 ns

迴圈 n 次 -> 循環 n 次

這裡與簡體中文相同都是用"循環"

e.g. 使用 for 迴圈進行 n 次循環

https://rust-lang.tw/book-tw/ch03-05-control-flow.html
在程式中用條件判斷迴圈的執行通常是很有用的。當條件為 true 時,迴圈就繼續執行。當條件不再是 true 時,程式就用 break 停止迴圈。這樣的循環行為可以用 loop、if、else 和 break 組合出來。

image

@krahets
Copy link
Owner Author

krahets commented Mar 26, 2024

迴圈 n 次 -> 循環 n 次

@Shyam-Chen 这里保留 迴圈 n 次 是不是也可以?(考虑到需要根据语义替换的复杂性,如果没有错误,倾向于不改动)

我在 Wiki 「迴圈」中没有找到 循環 关键词,一般用 執行 n 次。我们这里使用“迴圈 n 次”是否不影响理解?
https://zh.wikipedia.org/zh-tw/%E8%BF%B4%E5%9C%88

反碼 -> 一補數
補碼 -> 二補數
列列尾部 -> 佇列尾部
區域性性 -> 區域性
一摞 -> 一疊
推匯 -> 推導
@krahets krahets changed the base branch from main to dev_s2c_ref April 4, 2024 13:23
@krahets krahets changed the base branch from dev_s2c_ref to main April 4, 2024 13:37
@krahets krahets changed the base branch from main to dev_s2c_ref April 4, 2024 13:41
@krahets krahets changed the base branch from dev_s2c_ref to main April 4, 2024 13:45
@krahets
Copy link
Owner Author

krahets commented Apr 4, 2024

(Sorry for the ugly commit history...)

@Shyam-Chen @Dr-XYZ @kkbruce Do you think the current version is qualified to be released to the web?

@Dr-XYZ
Copy link
Contributor

Dr-XYZ commented Apr 5, 2024

  • 記憶體洩漏 -> 記憶體流失
    圖片

Shyam-Chen Dr-XYZ kkbruce Do you think the current version is qualified to be released to the web?

我目前只看到 chapter_searching,剩下的我無法確認

@Shyam-Chen
Copy link
Contributor

  • Recursion - 递归 - 遞迴
    • "递:" - "遞:"
    • "归:" - "歸:" - Inconsistency between the image ("迴:") and the code ("歸):").

記憶體洩漏 -> 記憶體流失
Add zh-Hant/README.md
@Shyam-Chen
Copy link
Contributor

I think it can be released.

@krahets
Copy link
Owner Author

krahets commented Apr 5, 2024

@Shyam-Chen @Dr-XYZ Thank you for the wonderful review! We've fixed many obvious bugs, and I believe this version should now be "worth reading".

I'll be releasing this version to the web, and hopefully we can continue to optimize it in the future to provide a better reading experience for Traditional Chinese readers.

If you find new mistakes, please comment in #1171 or submit a PR (also comment in #1171).

@krahets krahets merged commit 5f7385c into main Apr 5, 2024
1 check passed
@krahets krahets deleted the dev_s2c branch April 5, 2024 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code Code-related documents documents-related translation English translation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants