We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
由于用了四舍五入最左端和最右端的两个数字出现的概率是中间其他数字的一半
The text was updated successfully, but these errors were encountered:
有什么好的实现方法吗,用Math.floor吗
Sorry, something went wrong.
是的,我改成这样了 public limitInteger($from: number, $end: number): number { return Math.floor(this.limit($from, $end + 1)); } 结果是左闭右闭,不加一就是左闭右开
public limitInteger($from: number, $end: number): number { return Math.floor(this.limit($from, $end + 1)); }
ok 多谢
No branches or pull requests
由于用了四舍五入最左端和最右端的两个数字出现的概率是中间其他数字的一半
The text was updated successfully, but these errors were encountered: