All submissions for this problem are available.
In a company an emplopyee is paid as under:
If his basic salary is less than Rs. 1500, then HRA = 10% of base salary and DA = 90% of basic salary.
If his salary is either equal to or above Rs. 1500, then HRA = Rs. 500 and DA = 98% of basic salary. If the Employee's salary is input, write a program to find his gross salary.
NOTE: Gross Salary = Basic Salary + HRA + DA
The first line contains an integer T, total number of testcases. Then follow T lines, each line contains an integer salary.
Output the gross salary of the employee. Your answer will be considered correct if the absolute error is less than 10-2.
- 1 ≤ T ≤ 1000
- 1 ≤ salary ≤ 100000
Input 3 1203 10042 1312 Output 2406.00 20383.16 2624
|Time Limit:||1 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.5, PYPY, CS2, PAS fpc, PAS gpc, RUBY, PHP, GO, NODEJS, HASK, SCALA, D, PERL, FORT, WSPC, ADA, CAML, ICK, BF, ASM, CLPS, PRLG, ICON, SCM qobi, PIKE, ST, NICE, LUA, BASH, NEM, LISP sbcl, LISP clisp, SCM guile, JS, ERL, TCL, PERL6, TEXT, SCM chicken, CLOJ, FS|
Fetching successful submissions
If you are still having problems, see a sample solution here.