Answer:
The program is written as
#include<iostream>
int main()
{
//declare variables that we are going to need
//to store user input, and number of points
into books, points;
//prompt the user to enter number of books bought
//and read from keyboard
cout << "How many books have you bought this month?\\";
cin >> books;
//use switch statement to determine number of points
//awarded according to number of books, and set that to
//variable points
switch (books){
case 0:
points = 0;
break;
case 1:
points = 5;
break;
case 2:
points = 15;
break;
case 3:
points = 30;
break;
default:
points = 60;
break;
}
//print number of points on screen
cout << "The number of points you have earned this month is " << points << ".\\";
//return 0 to mark successful completion of program and return to zero.
return 0;