HW18: Chapter 18

18.4: Define an interface specification for the Currency Converter and Check credit rating services shown in Figure 18.7.

 Currency Converter

Operation: convert(), exchangeRate()

Input: typeIn(String), typeOut(String), amountIn(double)

Output: amountOut(double), rate(double)

Exception: incorrect typeIn, incorrect typeOut, incorrect amountIn

 

Check Credit Rating

Operation: checkCredit()

Input: ssNum(integer)

Output: creditScore(integer)

Exception: incorrect ssNum

Leave a Reply

Your email address will not be published. Required fields are marked *