What value is produced by the following functions?
Write a Boolean function for each of the following. Introduce variables as appropriate.
Write a function that consumes a bank account number, and produces the account balance, as shown in the following table. If the account number is not in the table, the function should produce −1.
Account number | Account Balance |
107 | $46.82 |
108 | $38.24 |
109 | $101.77 |
(cond
[(= account-number 107) 46.82]
[(= account-number 108) 38.24]
[(= account-number 109) 101.77]
[else −1]))