Summer Deals - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
Summary
13. Task

Instruction

Show us what you've got!

Exercise

An internet campaign was held in a few countries. The results are stored in a CSV file named campaign.csv.

country,purchase
Spain,no
UK,yes
UK,no
...

Each row represents a single person that clicked on a campaign banner. The purchase column indicates whether or not the given person made a purchase.

Your task is to create a simple report in a file named campaign_results.csv. It should contain country names along with their conversion rates (i.e., the number of people who made a purchase divided by the total number of people from that country):

Spain,0.625
UK,0.5
...