I once programmed up an artificial neural network (in C++) to calculate "winning" lottery numbers based on my personal incorrect numbers.
My premise (which I didn't take seriously myself, even at the time -- but I found amusing to tell people) was that "my picks are not just wrong, but so
completely wrong, that there
must be a correlation!"
Each week I would buy a $1 lottery ticket, then later record the winning numbers for that week, once the actual winning numbers were drawn.
Then I would train the neural network based on all my incorrect picks and all the corresponding winning numbers. The neural network always converged well. After training it would always predict the correct corresponding winning number set for any given previous incorrect pick. And each week I had a new data point for the training set, so I would retrain it weekly.
The goal was that eventually, I would purchase a new 1$ lottery ticket as usual, enter it into the neural network, and let it predict the winning number set. Then I would go back and purchase a second lottery ticket using the predicted number set, before the drawing.
Unfortunately, (and I suppose I should have known this) no matter how large the training set got, the neural network would always predict an exact copy of a set of previous winning numbers, no matter how random the inputs were.

In other words, if my training set had 100 different "original pick"-"winning set" combinations, when put to the test it would seem to limit itself to predicting a "winning set" from one of only those 100. (And it trained
itself to do this -- there was nothing in the algorithms that would explicitly force this behavior.) Eventually California changed the way it's lottery was played, and I stopped after that.
But I don't consider any of it a waste of time or money. I wasn't actually expecting to win. It was more of an excuse to create and play around with an artificial neural network. That was fun.

<I'm such a nerd sometimes>
[Edit: the moral of the story is every time I see someone buying a lottery ticket, I figure they're testing out their artificial neural network.]