Ask Question

Assume that a function with this header: function amountSaved (price, discountRate, salesTaxRate) already exists. Write a single line of jа vascript code to call that function and assign the value returned from that function to a variable named saved.

+2
Answers (1)
  1. 10 November, 23:57
    0
    let saved = amountSaved (12, 0.9, 0.06);

    Explanation:

    By presuming there is a jа vascript function amountSaved () that takes three input parameters, price, discountRate & salesTaxRate. To call the function, just simply write the function name, amountSaved followed with a pair of parenthesis. Within the parenthesis, include three testing values, 12, 0.9, 0.06 as arguments. These argument values will be held by the three parameter price, discountRate and salesTaxRate, respectively.

    The function will operate on the three input values and return the result to the main program where the returned result is assigned to a variable name saved.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Assume that a function with this header: function amountSaved (price, discountRate, salesTaxRate) already exists. Write a single line of ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers