Some example programs I've written.
Jack is a Python program I wrote for school as my final project in an AI course. It is a machine learning program which utilizes something called Q-learning to teach itself through trial and error how to play nearly optimal blackjack, and does so in under 1000 hands and well under a second. Jack.py was happily executable as of several years ago, but may need to be touched up for Python 3. When run, it will present you with a few demo options for comparison.
- Project summary
- Jack.py: main method and all the interesting bits
- Blackjack.py: blackjack logic
- BlackjackAgents.py: for comparison (random player, optimal player, always hit, always stand)
makeChange.py is a program I wrote recently for a job application to solve an optimization problem: given a set of coin denominations with arbitrary values, and a sum to total to, return the minimum number of coins necessary to reach that sum.