A store is having a sale on chocolate chips and walnuts. For 3 pounds of chocolate chips and 5 pounds of walnuts, the total cost is $24. For 9 pounds of chocolate chips and 7 pounds of walnuts, the total cost is $42. Find the cost for each pound of chocolate chips and each pound of walnuts.