Computer Science, asked by aaronprince5559, 1 month ago

A pension rule of a certain country state that a person receives Rs 2000/- a month , if he/she is over 70 years of age and extra Rs 500/- if he/she is over 80 years. Write a program to accept the age of a person and print the amount of monthly pension they would get. If a person is below the pensionable age , then display the message “Not eligible for pension”.

Answers

Answered by sachinsomani12
1

Answer:

#include<iostream>

int main()

{

    int age,pension=2000;

    cin>>age;

     if(age>=80)

     {

          pension = pension+500;

          cout<<"monthly pension : "<<pension;

     }

     else if(age>=70 && age<80)

     {

          cout<<"monthly pension : "<<pension;

      }

      else

      {

          cout<<“Not eligible for pension”;

      }

}

Explanation:

Similar questions