Menu Close

Classify the salary of a person

Agathiyan is the Chief In charge for carrying out World Economic Survey in India. As a part of survey his team have collected the salaries of the citizens of India. The Salaries of different people are in different number of digits.

Now Agathiyan would like to classify the  earnings of the citizen based on the number of digits of his/her salary into 5 different categories as follows:

1.Insufficient Earning
2.Very Low Earning
3.Low Earning
4.Sufficient Earning
5.High Earning

Can you help him do the above classification if he gives the salary of the particular person to you as input?

Input:
Input will contain the number N.

Output:
Print "Insufficient Earning" if N is a 1 digit number.

Print "Very Low Earning" if N is a 2 digit number.

Print "Low Earning" if N is a 3 digit number.

Print "Sufficient Earning" if N has 4 digits.

Print "High Earning" if N has more than 4 digits.
#include <stdio.h>
int main()
{int N;
scanf("%d",&N);
if(N<10)
printf("Insufficient Earning");
else if(N<100)
printf("Very Low Earning");
else if(N<1000)
printf("Low Earning");
else if(N<10000)
printf("Sufficient Earning");
else if(N>10000)
printf("High Earning");
	return 0;
}

INPUT_1:
 73

OUTPUT:
Very Low Earning



Morae Q!