60 521
Assignments Done
98,2%
Successfully Done
In April 2018

# Answer to Question #45294 in C# for Nikita Maheshwari

Question #45294
Develop the program, which accepts the gross pay and produces the amount of tax owed. For a gross pay of 100000 or less, the tax is 0%; for over 100000 and 300000 or less, the tax rate is 15%; and for any pay over 300000, the tax rate is 28%. Calculate tax pay and return the result to main method. Print the result in main method.
using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace amount_of_tax_owed{    class Program    {      &nbsp; //main method      &nbsp; static void Main(string[] args)      &nbsp; {            //promt user to enter gross pay            Console.Write(&quot;Enter the gross pay: &quot;);            //read gross Pay            double grossPay = double.Parse(Console.ReadLine());            double taxPay = 0;            // gross pay of 100000 or less, the tax is 0%            if (grossPay &lt; 100000)            {                taxPay = 0;            }            //for over 100000 and 300000 or less, the tax rate is 15%            if (grossPay &gt; 100000 &amp;&amp; grossPay &lt; 300000)            {                taxPay = 0.15 * grossPay;            }            // any pay over 300000, the tax rate is 28%            if (grossPay &gt; 300000)            {                taxPay = 0.28 * grossPay;            }            //show Tax pay            Console.WriteLine(&quot;Tax pay : \$&quot; + taxPay.ToString());            //delay            Console.ReadLine();      &nbsp; }    }}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!