To calculate cost-per-click (CPC) you take the total dollar amount spent for a given time period and you divide by the amount of clicks for that same time period.
Total Spend / Total Clicks = CPC
Example: Mark ran a AT&T display campaign last month that drove 1,983,092 impressions, 2,365 clicks with a 0.12% CTR. The total campaign spend was $3,415. The CPC for that AT&T display campaign last month was $1.44 (3,415 / 2,365 = 1.4439).