473,474 Members | 1,682 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Where seed from srand() is stored?

Hello,

I would like to know where the seed from the srand() is stored i.e. in
thread context or global to a process?

Thank you,
-Pandit
Nov 17 '05 #1
1 1025
"Pandit" <Pa****@discussions.microsoft.com> wrote in message
news:81**********************************@microsof t.com...
I would like to know where the seed from the srand() is stored i.e. in
thread context or global to a process?


That depends on which version of the library you use. The multi-threaded
library stores it in the "per-thread" data structure.

Regards,
Will
Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

19
by: Peter Ammon | last post by:
I'm calling random_shuffle without passing in a RandomNumberGenerator and getting the same shuffle every time I restart my program. Apparently I need to seed the internal random number generator. ...
1
by: Wavelet | last post by:
If I use srand(value) to change the random seed, when I close the vc or run the code from the beginning, the seeds of random will change to default value or still keep the value of what I designed...
9
by: Frederik | last post by:
Hi all, I'm building a C# application that uses a M$ Acces database. In one of the queries I use something like the following: SELECT id FROM mytable WHERE id IN (20, 12, 21, 14) The result...
25
by: Nikola | last post by:
compiler says: function undeclared how come??? help! #include<stdio.h> #include<stdlib.h> #include<time.h> struct lista{ int element; struct lista *next; }*pocetak;
23
by: Red Dragon | last post by:
I am self study C program student. Hope someone can help me with this problem. This program generates random numbers over a user defined range using call function I used the call function "...
4
by: ajikoe | last post by:
Hello, I tried calling RandomArray.seed() by calling RandomArray.get_seed() I get the seed number (x,y). My problem is that x is always 113611 any advice? Thanks pujo
11
by: jtagpgmr | last post by:
I am currently using the gcc compiler on a cygwin platform, I am a beginner when it comes to programming in C and want to know why anytime I run the .exe with the following code I get a...
3
by: divya | last post by:
Hi, I have a table tblbwday with 2 fields Name and Birthday.I have written this script for displaying evryday names of the people on that day. <% set objConn...
4
by: kalar | last post by:
Hello everyone,I don't speak very good english , so sorry if i make any mistake Can anyone explain me this code unsigned int rand_seed = 1; void srand(unsigned int seed) { rand_seed =...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.