Implemented greedy AI