Skip to content

Commit

Permalink
docs: include stdbool, remove backticks
Browse files Browse the repository at this point in the history
  • Loading branch information
gunjjoshi committed Sep 7, 2024
1 parent 8bcb738 commit 00e2904
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ var isNonNegativeInteger = require( '@stdlib/math/base/assert/is-nonnegative-int

#### isNonNegativeInteger( x )

Tests if a finite [double-precision floating-point number][ieee754] is a nonnegative `integer`.
Tests if a finite [double-precision floating-point number][ieee754] is a nonnegative integer.

```javascript
var bool = isNonNegativeInteger( 1.0 );
Expand All @@ -53,7 +53,7 @@ bool = isNonNegativeInteger( -10.0 );

## Notes

- The function assumes a **finite** `number`. If provided positive `infinity`, the function will return `true`, when, in fact, the result is undefined. If `x` can be `infinite`, wrap the implementation as follows:
- The function assumes a **finite** number. If provided positive `infinity`, the function will return `true`, when, in fact, the result is undefined. If `x` can be `infinite`, wrap the implementation as follows:

```javascript
function check( x ) {
Expand Down Expand Up @@ -141,6 +141,8 @@ bool = isNonNegativeInteger( NaN );
Tests if a finite [double-precision floating-point number][ieee754] is a nonnegative integer.

```c
#include <stdbool.h>

bool out = stdlib_base_is_nonnegative_integer( 1.0 );
// returns true

Expand Down

0 comments on commit 00e2904

Please sign in to comment.