diff options
| author | nic-gaffney <gaffney_nic@protonmail.com> | 2023-06-25 23:21:02 -0500 |
|---|---|---|
| committer | nic-gaffney <gaffney_nic@protonmail.com> | 2023-06-25 23:21:02 -0500 |
| commit | c3bb1751d7f62a13a46f28c1eb67d9e20d8d6f7f (patch) | |
| tree | 7208642d10240c539405b4e1759576d3da5f468a /std/stdmath.c | |
| parent | 578229132e35075ef191ee960460d237c3ace3b8 (diff) | |
| download | sloth-c3bb1751d7f62a13a46f28c1eb67d9e20d8d6f7f.tar.gz | |
Fixed standard library
Diffstat (limited to 'std/stdmath.c')
| -rw-r--r-- | std/stdmath.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/std/stdmath.c b/std/stdmath.c index c9a91c3..dad292f 100644 --- a/std/stdmath.c +++ b/std/stdmath.c @@ -2,10 +2,8 @@ #include <stdlib.h> #include <time.h> -int randGen(int min, int max) { - time_t t; - - srand((unsigned) time(&t)); - - return rand() % (max - min + 1) + min; + +long long randGen(long long min, long long max) { + srandom((unsigned) time(NULL)); + return random() % (max - min + 1) + min; } |
