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

fix: 修复中文数字转换函数对'十、十一'等数字的处理 #275

Merged
merged 1 commit into from
Nov 27, 2024

Conversation

dludream
Copy link
Contributor

问题描述

当前的 chinese_to_number 函数在处理某些中文数字(如"十、十一")时存在问题。

修改内容

  • 添加了对以"十"开头的数字的特殊处理
  • 优化了数字转换逻辑

测试用例

  • "十" => 10
  • "十一" => 11
  • "二十" => 20
  • "二十一" => 21

测试结果

所有测试用例均通过。

@hanxi hanxi merged commit 9a1b9d1 into hanxi:main Nov 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants