Welcome Guest
Log In | Register )
You last visited December 7, 2016, 9:19 am
All times shown are
Eastern Time (GMT-5:00)

Pick 4 - add 0 to 9999 limit 10000 rows

Topic closed. 13 replies. Last post 2 years ago by SergeM.

Page 1 of 1
52
PrintE-mailLink
SergeM's avatar - slow icon.png
Economy class
Belgium
Member #123700
February 27, 2012
4035 Posts
Offline
Posted: May 14, 2015, 6:44 pm - IP Logged

  Link: Addition of a value between 0 and 9999

  Limit 10000 rows!

  Enter your first four digits or not.
  Enter your value to add, like 0023 = 23.

  %=10000 per value.

    SergeM's avatar - slow icon.png
    Economy class
    Belgium
    Member #123700
    February 27, 2012
    4035 Posts
    Offline
    Posted: May 15, 2015, 12:54 pm - IP Logged

      For the systems above, you can now use negative values.

      lakerben's avatar - spherewall
      New Mexico
      United States
      Member #86099
      January 29, 2010
      11119 Posts
      Offline
      Posted: May 15, 2015, 11:14 pm - IP Logged

      What is the two limit rundown?

      How about them cowboys!

       

       

      US Flag

        SergeM's avatar - slow icon.png
        Economy class
        Belgium
        Member #123700
        February 27, 2012
        4035 Posts
        Offline
        Posted: May 16, 2015, 5:45 am - IP Logged

        The amount of rows is variable and depends of your input.

        If you add 0 0 1 to 0 0 0 for pick 3, you create 1000 rows ranging from 000 to 999.

        The added value cannot be negative here. To create -1 you have to add 999.

         

        I give two options for the addition:

        • by position
        • combination as value

         

        The first two systems are:

        • separate start combination +/- 0|1 for each position
        • separate start combination +/- user input for the specific position

          Avatar
          Krypton
          United States
          Member #140102
          March 11, 2013
          891 Posts
          Offline
          Posted: May 16, 2015, 7:27 am - IP Logged

            Link: Addition of a value between 0 and 9999

            Limit 10000 rows!

            Enter your first four digits or not.
            Enter your value to add, like 0023 = 23.

            %=10000 per value.

          Serge,

          What is this about, can you explain or is this a way t get all the combinations of a P4?

          Stay In The Vortex, you'll be happy you did ..... Random? Seriously? You want me to believe that?

            SergeM's avatar - slow icon.png
            Economy class
            Belgium
            Member #123700
            February 27, 2012
            4035 Posts
            Offline
            Posted: May 16, 2015, 10:52 am - IP Logged

            You better play with the tool instead of asking me.

              lakerben's avatar - spherewall
              New Mexico
              United States
              Member #86099
              January 29, 2010
              11119 Posts
              Offline
              Posted: May 16, 2015, 10:54 am - IP Logged

              The amount of rows is variable and depends of your input.

              If you add 0 0 1 to 0 0 0 for pick 3, you create 1000 rows ranging from 000 to 999.

              The added value cannot be negative here. To create -1 you have to add 999.

               

              I give two options for the addition:

              • by position
              • combination as value

               

              The first two systems are:

              • separate start combination +/- 0|1 for each position
              • separate start combination +/- user input for the specific position

              Is the additive the first entry or the second one?

              How about them cowboys!

               

               

              US Flag

                SergeM's avatar - slow icon.png
                Economy class
                Belgium
                Member #123700
                February 27, 2012
                4035 Posts
                Offline
                Posted: May 16, 2015, 11:00 am - IP Logged

                Is the additive the first entry or the second one?

                1. Digits of combination
                2. Digits to add at each step

                You guess it with the first use.

                I could put comments, but it is so simple.

                  lakerben's avatar - spherewall
                  New Mexico
                  United States
                  Member #86099
                  January 29, 2010
                  11119 Posts
                  Offline
                  Posted: May 16, 2015, 11:06 am - IP Logged

                  Cool!

                  I'll give it  try here shortly for the morning draw.  I'm experimenting with using digits from the root, width for the next draw.

                  Thanks for the work!

                  Thumbs Up

                  How about them cowboys!

                   

                   

                  US Flag

                    SergeM's avatar - slow icon.png
                    Economy class
                    Belgium
                    Member #123700
                    February 27, 2012
                    4035 Posts
                    Offline
                    Posted: May 16, 2015, 11:18 am - IP Logged

                    It does the job you ask it to do. The length of the result depends of the input. Filters and extra functions would make it more complicated. Since the new record is the return of a rest function, the list stops before the first combination. You could start with a rest as combination, add a value bigger than the rest and only take the combinations <= 9999. Since the program does not have a break, you get the list in the order of the calculations.

                    Example:
                    Divisor: 11
                    Rest: 2
                    Input combination: 0002
                    Input value to add: 0011
                    Run the program, pick the first values <= 9999.
                    These are all values that after division by 11 have a rest of 2.

                    record /*belongs to*/ 2 mod 11 when the record belongs to the first records <= 9999

                    After 9999 the list continues, as operations are computed.
                    You find more in it when you try and read the results.
                    Make the experience!

                      SergeM's avatar - slow icon.png
                      Economy class
                      Belgium
                      Member #123700
                      February 27, 2012
                      4035 Posts
                      Offline
                      Posted: May 16, 2015, 11:34 am - IP Logged
                      1. 002
                      2. 113
                      3. 224
                      4. 335
                      5. 446
                      6. 557
                      7. 668
                      8. 779
                      9. 890
                      10. 001
                      11. 112
                      12. 223
                      13. ...

                       

                      REST 2
                      DIVISOR 111
                      RECORDS: 1 to 9
                      CONDITION: REC%11==2

                        Avatar
                        Krypton
                        United States
                        Member #140102
                        March 11, 2013
                        891 Posts
                        Offline
                        Posted: May 16, 2015, 12:46 pm - IP Logged

                        You better play with the tool instead of asking me.

                        Now that I checked it out, hmmmm I don't understand  LOL  kidding   thanks!!

                        Stay In The Vortex, you'll be happy you did ..... Random? Seriously? You want me to believe that?

                          Raven62's avatar - binary
                          New Jersey
                          United States
                          Member #17843
                          June 28, 2005
                          49725 Posts
                          Offline
                          Posted: May 16, 2015, 1:58 pm - IP Logged
                          1. Digits of combination
                          2. Digits to add at each step

                          You guess it with the first use.

                          I could put comments, but it is so simple.

                          It's simple when you know the Functions of each Box: We don't!

                          What's needed: A description/explanation of how it works.

                          A mind once stretched by a new idea never returns to its original dimensions!

                            SergeM's avatar - slow icon.png
                            Economy class
                            Belgium
                            Member #123700
                            February 27, 2012
                            4035 Posts
                            Offline
                            Posted: May 16, 2015, 2:21 pm - IP Logged

                            It's simple when you know the Functions of each Box: We don't!

                            What's needed: A description/explanation of how it works.

                            It was written in the very first comment.

                            %=10000 per value

                            % , mod and rest() are the same. In this case you could use right().

                            x%=10000;

                            Assign x mod 10000 to x.

                            Basically:

                            Dim x, y, z as Integer
                            x = x + y
                            x = x mod z

                            int x,y,z;
                            x+=y;
                            x%=z;

                            Same as by digit: x%=10;

                            Of course you did x+=some_value;

                            I need to do other things first. I supposed you all know your basic college mathematics.

                            The rest is logic, there you fail.