#Speeding tickets result in points and cause increase in insurance rates. #Write a program that calculates the new yearly insurance preminum and #monthly insurance payment for the next insurance term after the person #receives violation points. #Input: #the current insurance cost per year and the number of points person #received in current year (integer). #Output: #1. the new yearly insurance premium #2. the new monthly payment. #Use the following table: #Insurance Rate Increase based on Speeding Points #points: rate increase in percent #3 points and more: 25% increase #1-2 points: 10% increase #NO POINTS: NO rate increase (0%) #We will check validity of the input #Input current_insurance=float(input("enter your current insurance yearly amount ")) points=int(input("enter number of points ")) if(current_insurance>0): if(points>=3): new_rate_year=current_insurance+current_insurance*25/100 new_monthly=new_rate_year/12 print("new yearly rate", format(new_rate_year ,'.2f')) print("new monthly", format(new_monthly,'.2f')) elif(points<=2 and points>=1): #or elif(points>=1): new_rate_year=current_insurance+current_insurance*10/100 new_monthly=new_rate_year/12 print("new yearly rate", format(new_rate_year ,'.2f')) print("new monthly", format(new_monthly,'.2f')) elif(points==0): new_rate_year=current_insurance new_monthly=new_rate_year/12 print("new yearly rate", format(new_rate_year ,'.2f')) print("new monthly", format(new_monthly,'.2f')) else: print("invalid input") else: print("invalid input")