4. TABLE 1 below shows the taxrate for pairs of status and income ranges. TABLE 1 status 1 1 1 2 2 2 income <=30000 <=50000 >50000 <=60000 <=100000 >100000 taxrate .02 .04 .07 .10 .12 .15 Write Java code for a method named computeTaxrate that accepts two integers and returns the taxrate as specified by the table. For example, if status of 1 and income of 25000 were passed to computeTaxrate, it would return a value of .02 If 2 and 85000 were passed, it would return a value of .12

EBK JAVA PROGRAMMING
8th Edition
ISBN:9781305480537
Author:FARRELL
Publisher:FARRELL
Chapter16: Graphics
Section: Chapter Questions
Problem 1DE
icon
Related questions
Question

Please written by computer source

 

java please 

4.
TABLE 1 below shows the taxrate for pairs of status and income ranges.
TABLE 1
status
1
1
1
2
2
income
<=30000
<=50000
>50000
<=60000
<=100000
>100000
taxrate
.02
.04
.07
.10
.12
.15
Write Java code for a method named computeTaxrate that accepts two integers and
returns the taxrate as specified by the table. For example, if status of 1 and income of
25000 were passed to computeTaxrate, it would return a value of .02 If 2 and 85000
were passed, it would return a value of .12
Transcribed Image Text:4. TABLE 1 below shows the taxrate for pairs of status and income ranges. TABLE 1 status 1 1 1 2 2 income <=30000 <=50000 >50000 <=60000 <=100000 >100000 taxrate .02 .04 .07 .10 .12 .15 Write Java code for a method named computeTaxrate that accepts two integers and returns the taxrate as specified by the table. For example, if status of 1 and income of 25000 were passed to computeTaxrate, it would return a value of .02 If 2 and 85000 were passed, it would return a value of .12
Expert Solution
steps

Step by step

Solved in 3 steps with 2 images

Blurred answer
Knowledge Booster
Array
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781305480537
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT