Building blocks in Python

Published:

Toward the new experiment, pieces of the puzzle have been unlocked!

A loop to increment a list as if it were a counter has been tested. It works!

A passing of a list from one function to the other, along with a data frame column has also worked.

Appending the hit count to the end of the list has also worked.

The current challenge is to create the running top 10 list of lists and have it populate and pop off the low list (by hit count). Going to work with the Python heapq (heap queue) library to enable this functionality.

Using a loop to increment the list has the advantage of being able to run the top 10 comparison within the loop, then print the top 10 list to both the screen and to a .csv file when done iterating.

The next challenge will be to figure out how to get the right comparison such that it looks at the row before,  finds the number in the list at that index, and compares it to the next row to see if it was a match.

Then the final challenge is to put all of these parts together and solve the puzzle.

Then the hardware...

The Raspberry Pi 5 has an 8GB version that ships with a case that has a cooling fan, a 128gb mmicro sd card, a power supply and a giant heat sink. These single board computers can run constantly for decades... it is what they were designed to do! The board itself is $80, but the kit with all the parts runs $170. I already have a raspberry pi version 3b, that only has 1gb of ram. Both have a tiny form factor, about the size of a double deck of cards.

When the experiment is finished, i can use this new Pi to act as a better server for learning web technologies, so the investment has use beyond the lottery number crunching hobby. I can also put the GPIO board on the older Pi and learn some IoT electronics.

The use of a loop to iterate the lists has one more advantage... I can set the start and end points, therefore a limited test can be run to check the validity of the software BEFORE getting into the 10 billion loops. 

Did I mention that the Pi can run headless? That means no monitor, keyboard or mouse required. Once set up I can log in remotely with a program called PuTTY to check progress and download results.

At the end of this, the largest coding project I have ever undertaken, if it fails to produce hits it will still have been worth the effort since the puzzle pieces learned here can be used to solve other problems. I sort of look at this as an exhaustive backtest. A brute force effort to run through 280 billion possibilities (all possible iterations of the replacement scenario of which mirrors are but one) and I can truly say I have tried everything in the attempt at a single pick straight shooter system.

Entry #275

Comments

This Blog entry currently has no comments.

Post a Comment

Please Log In

To use this feature you must be logged into your Lottery Post account.

Not a member yet?

If you don't yet have a Lottery Post account, it's simple and free to create one! Just tap the Register button and after a quick process you'll be part of our lottery community.

Register