Skip to content

Include behaviour of integer division #2248

Closed
rust-lang/rust
#87503
@coolshaurya

Description

@coolshaurya

So in the Numeric Operations section, I think integer division should be covered as it may be a bit confusing that 4999/1000 gives 4 and not 5 to people coming from languages like javascript where numbers aren't separated into ints and floats.

Something like -

With integers, division is automatically floored so doing 4999/1000 will give 4 and not 5.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions