# BigInt & number

### `bnToHex`

Convert bigint to hex

```typescript
import { bnToHex } from 'dedot/utils';
```

### `bnToU8a`

Convert bigint to Uint8Array

```typescript
import { bnToU8a } from 'dedot/utils';
```

### `bnMax`

Return the bigger bigint value

```typescript
import { bnMax } from 'dedot/utils';
```

### `bnMin`

Return the smaller bigint value

```typescript
import { bnMin } from 'dedot/utils';
```

### `bnAbs`

Return the absolute value of a bigint

```typescript
import { bnAbs } from 'dedot/utils';
```

### `numberToHex`

Convert a number to a hex string

```typescript
import { numberToHex } from 'dedot/utils';
```

### `numberToU8a`

Convert a number to a Uint8Array

```typescript
import { numberToU8a } from 'dedot/utils';
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.dedot.dev/utilities/bigint-and-number.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
