Final version project 4: 100%, will do optimization now