Income Tax Calculate
function calculateTax(income, deductions, ageGroup) {
let taxableIncome = income - deductions;
let tax = 0;
if (ageGroup === "below60") {
if (taxableIncome <= 250000) tax = 0;
else if (taxableIncome <= 500000) tax = (taxableIncome - 250000) * 0.05;
else if (taxableIncome <= 1000000) tax = 12500 + (taxableIncome - 500000) * 0.2;
else tax = 112500 + (taxableIncome - 1000000) * 0.3;
}
// Add conditions for other age groups
return tax;
}
Income Tax Calculator