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

Documentation of rand_float() is incorrect. #6

Open
your-diary opened this issue May 28, 2024 · 1 comment
Open

Documentation of rand_float() is incorrect. #6

your-diary opened this issue May 28, 2024 · 1 comment
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@your-diary
Copy link

Document (emphasis mine)

link

rand_float(start: f64, end: f64) -> f64

Generate a random floating-point number within an exclusive range.

Implementation (comment mine)

link

Ok(rand::thread_rng().gen_range(start..=end)) //inclusive
@schungx
Copy link
Contributor

schungx commented May 29, 2024

Ah OK. A PR is welcome!

@schungx schungx added bug Something isn't working documentation Improvements or additions to documentation labels May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants