473,326 Members | 2,680 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Randomize..

29
Under what circumstances is it desirable not to randomize?
Jan 17 '07 #1
16 4616
RedSon
5,000 Expert 4TB
In most circumstances you would not want to randomize your data. Can you provide a little context for your question?
Jan 17 '07 #2
elsa
29
well..it is just a question i have to answer from the book..so if u can give me some general information, it would be great..and thx alot for replying..
Jan 17 '07 #3
RedSon
5,000 Expert 4TB
I'm sorry your question is too general to give a coherent answer out of context. You may want to consider forming a study group with some of the other members of your class.
Jan 17 '07 #4
elsa
29
ok thx anyway..
Jan 17 '07 #5
Motoma
3,237 Expert 2GB
Randomization can be useful in a lot of situations, however, there are times when pseudo-randomness is better.
Consider the following situation: you are writing a program which uses a random number generator to determine the actions which the program follows. Durring the testing phase of this application, you hit a circumstance where the code goes horribly wrong. It would be nice if you could control and repeat the random number sequence that gave you the erroneous results.
Another situation to consider is in benchmarking a piece of software which uses random numbers. If the length of time a function runs is based on a set of random numbers, controlling those numbers will allow you to give a best and worst case scenario.

Hope this helps,
Motoma
Jan 17 '07 #6
elsa
29
thx alot for ur reply..it really helps..
Jan 17 '07 #7
RedSon
5,000 Expert 4TB
Randomization can be useful in a lot of situations, however, there are times when pseudo-randomness is better.
Consider the following situation: you are writing a program which uses a random number generator to determine the actions which the program follows. Durring the testing phase of this application, you hit a circumstance where the code goes horribly wrong. It would be nice if you could control and repeat the random number sequence that gave you the erroneous results.
Another situation to consider is in benchmarking a piece of software which uses random numbers. If the length of time a function runs is based on a set of random numbers, controlling those numbers will allow you to give a best and worst case scenario.

Hope this helps,
Motoma
You two must have the same text book.
Jan 17 '07 #8
Motoma
3,237 Expert 2GB
You two must have the same text book.
Hah, no.
Just happened to do some work with randomization for my Capstone.
One thing that is often looked for in a random function is repeatability.
Jan 18 '07 #9
r035198x
13,262 8TB
Hah, no.
Just happened to do some work with randomization for my Capstone.
One thing that is often looked for in a random function is repeatability.
I still think you have the same book too because even though I knew all the hints you gave, I did not see how they applied directly to the question that was asked because no context was given for the question.

Q:Under what circumstances is it desirable not to randomize?
A:When playing my songs from an mp3 that has songs grouped by albums.
Jan 18 '07 #10
radders
13
Q:Under what circumstances is it desirable not to randomize?
A:When playing my songs from an mp3 that has songs grouped by albums.
Indeed if the book gives no context in the question you could have a laugh writing all sorts of arguably "correct" answers, for example:
When choosing a country's leader from the population
When deciding who plays in which position in a professional football team!
Radders
Jan 18 '07 #11
Motoma
3,237 Expert 2GB
Indeed if the book gives no context in the question you could have a laugh writing all sorts of arguably "correct" answers, for example:
When choosing a country's leader from the population
When deciding who plays in which position in a professional football team!
Radders
Yes, pseudo-randomness is the best choice in these situations for sure!
Jan 18 '07 #12
RedSon
5,000 Expert 4TB
Yea thanks for backing me up guys. This question was entirely too broad. It would be akin to asking "Which is a better screwdriver, phillips or flat head?"
Jan 19 '07 #13
Motoma
3,237 Expert 2GB
Yea thanks for backing me up guys. This question was entirely too broad. It would be akin to asking "Which is a better screwdriver, phillips or flat head?"
Honestly guys..This was posted in a C/C++ forum. One should assume, as such, the question was related to the language or the act of programming.
Jan 19 '07 #14
RedSon
5,000 Expert 4TB
Honestly guys..This was posted in a C/C++ forum. One should assume, as such, the question was related to the language or the act of programming.
I still maintain that even given the entire domain of the C/C++ language or the act of programming it is still too general of a question. Just my opinion, agree if you want to.
Jan 19 '07 #15
Motoma
3,237 Expert 2GB
I still maintain that even given the entire domain of the C/C++ language or the act of programming it is still too general of a question. Just my opinion, agree if you want to.
I guess we will just have to agree to disagree.
Jan 19 '07 #16
r035198x
13,262 8TB
I guess we will just have to agree to disagree.
No wonder this tomato is yellow.
Jan 20 '07 #17

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Fieldmedic | last post by:
I'm trying to determine the best way to randomize a set of array items. I'm thinking that I could use an arraylist and have it use the lower and upper bounds as the limits. Any suggestions? ...
3
by: Gaffer | last post by:
Hello Is there a way in which I can make certain parts of Html on my website random so that each viewer will see different material if they refresh the page or come back onto the website later?...
1
by: Ellen Manning | last post by:
I've got an A2K database with a report that generates any number of random medical record numbers. The user inputs how many numbers they want and report uses the Randomizer function found on "The...
4
by: Mr. x | last post by:
Hello, randomize is a function in vbscript. What is the function for vb ? (I have tried to use that command in the script in web-service of .net, which used VB and not VBScript). Thanks :)
2
by: Rich | last post by:
Here is what I am trying for randomizing 2 numbers in the same subroutine so that they are not equal to each other: Dim j As Integer, k As Integer j = New System.Random().Next(0, 10) k = New...
4
by: Arnold | last post by:
Hi there, Here's the situation--there is a text field in a form in which students will key in data. On the keypress event, I'd like for different sounds to be played for each character typed,...
1
by: Badass Scotsman | last post by:
Hello, This code is supposed to generate a random string each run, however I have had it live on a few sites, and it seems to create repeat strings all over the place. ...
6
by: mrtaka79 | last post by:
Okay, first of all, I'm a complete noob, so go easy on me. I have this code that works perfectly for me. The only thing I want to add is to randomize the pictures/links that show up. Can anyone...
1
by: VBSTUDENT | last post by:
I am just wondering if there is a way to randomize the aritmetic operators in code, I know how to randomize numbers but I am not sure if it is possible to randomize operators. Any help would be...
5
by: gggram2000 | last post by:
Hi, I'ved spent two full days trying to find a solution, I can randomize numbers between two ranges and it works fine, But my problem is when i want to randomize five numbers that I got. eg. I...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.