Answer:
Desired C++ Program with proper comment is given below
Step-by-step explanation:
#include<iostream>
using namespace std;
//main function
int main()
{
int totalMiles = 0;
int remainingMiles = 0;
double amt = 0;
//taking input from user regarind total miles
cout<<"Enter the total miles: "<<endl;
cin>>totalMiles;
//if-else condition to do the calculation
if(totalMiles<=100)
{
amt = totalMiles*.25;
}
else
{
remainingMiles = totalMiles - 100;
amt = 100*.25 + remainingMiles*.15;
}
cout<<"The total amount is: "<<amt<<endl;
}