Changed data type of cost
Slowly implementing