Randomize..

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • elsa
    New Member
    • Jan 2007
    • 29

    Randomize..

    Under what circumstances is it desirable not to randomize?
  • RedSon
    Recognized Expert Expert
    • Jan 2007
    • 4980

    #2
    In most circumstances you would not want to randomize your data. Can you provide a little context for your question?

    Comment

    • elsa
      New Member
      • Jan 2007
      • 29

      #3
      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..

      Comment

      • RedSon
        Recognized Expert Expert
        • Jan 2007
        • 4980

        #4
        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.

        Comment

        • elsa
          New Member
          • Jan 2007
          • 29

          #5
          ok thx anyway..

          Comment

          • Motoma
            Recognized Expert Specialist
            • Jan 2007
            • 3236

            #6
            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

            Comment

            • elsa
              New Member
              • Jan 2007
              • 29

              #7
              thx alot for ur reply..it really helps..

              Comment

              • RedSon
                Recognized Expert Expert
                • Jan 2007
                • 4980

                #8
                Originally posted by Motoma
                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.

                Comment

                • Motoma
                  Recognized Expert Specialist
                  • Jan 2007
                  • 3236

                  #9
                  Originally posted by RedSon
                  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.

                  Comment

                  • r035198x
                    MVP
                    • Sep 2006
                    • 13225

                    #10
                    Originally posted by Motoma
                    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.

                    Comment

                    • radders
                      New Member
                      • Jan 2007
                      • 13

                      #11
                      Originally posted by r035198x
                      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

                      Comment

                      • Motoma
                        Recognized Expert Specialist
                        • Jan 2007
                        • 3236

                        #12
                        Originally posted by radders
                        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!

                        Comment

                        • RedSon
                          Recognized Expert Expert
                          • Jan 2007
                          • 4980

                          #13
                          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?"

                          Comment

                          • Motoma
                            Recognized Expert Specialist
                            • Jan 2007
                            • 3236

                            #14
                            Originally posted by RedSon
                            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.

                            Comment

                            • RedSon
                              Recognized Expert Expert
                              • Jan 2007
                              • 4980

                              #15
                              Originally posted by Motoma
                              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.

                              Comment

                              Working...