Since the ratio of number of pens to its cost are in proportion.
We say that 12 : 96 :: 8 : cost
Product of extremes = 12 × cost
Product of means = 96 × 8 = 768
Product of extremes = product of means
12 × Cost = 96 × 8
Cost = (96×8)/12 = 64
Cost of 8 pens ₹ 64