Last change
on this file since 388 was 388, checked in by coas-nagasima, 5 years ago |
Azure IoT Hub Device C SDK を使ったサンプルの追加
|
-
Property svn:eol-style
set to
native
-
Property svn:keywords
set to
Id
-
Property svn:mime-type
set to
text/x-csrc
|
File size:
183 bytes
|
Line | |
---|
1 | #include <stdlib.h>
|
---|
2 | #include <stdint.h>
|
---|
3 |
|
---|
4 | static uint64_t seed;
|
---|
5 |
|
---|
6 | void srand(unsigned s)
|
---|
7 | {
|
---|
8 | seed = s-1;
|
---|
9 | }
|
---|
10 |
|
---|
11 | int rand(void)
|
---|
12 | {
|
---|
13 | seed = 6364136223846793005ULL*seed + 1;
|
---|
14 | return seed>>33;
|
---|
15 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.