A high-performance general-purpose compute library

- Main Page
- Tutorials
- Release Notes
- Examples

Functions
getSeed
ArrayFire Functions | ArrayFire Functions by Category » Functions to create and modify Arrays » Functions to create arrays. » Random Number Generation

Returns the seed for random number generation. More...

## Functions
AFAPI unsigned long long | getSeed ()
| C++ Interface to get the seed of the default random number generator.
AFAPI af_err | af_get_seed (unsigned long long *seed)

## Detailed Description

Returns the seed for random number generation.

Returns the seed for the current default random engine.

## Function Documentation

## ◆ af_get_seed()

AFAPI af_err af_get_seed | ( | unsigned long long * | seed | ) |

Parameters

  [out] | seed | a 64-bit unsigned integer

Returns
  AF_SUCCESS, if function returns successfully, else an af_err code is given

## ◆ getSeed()

AFAPI unsigned long long getSeed | ( |  | ) |

C++ Interface to get the seed of the default random number generator.

Returns
  seed 64-bit unsigned integer