AI class project using Q-learning algorithm