Get the App
SLTechnology News&Howtos  ›  Development  › 

How to realize the numerical normal Distribution of C++

Shulou Source: shulou.com Published: 2022-06-03 06:15:44 10月02日 Update

The main content of this article is "how to achieve the normal distribution of C++ values", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Next, let the editor take you to learn how to achieve the normal distribution of C++ numbers.

# include

# include

# include

# include

# include

# include

Whole Lord ()

{

/ / sow seeds with random values, if possible

Random device r

/ / Select a random number between 1 and 6

Mark:: default random engine E1 (r ())

Uniform distribution (1,6)

Integral average = uniform distribution (E1)

Output

Tags: Normal distribution average ratio output numerical value caterpillar uniform history seed content p. learning practical deeper interest practicality actual average sequence engine Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MySQL vpn Huawei NVidia Microsoft