Exercise 3: Place Order
Explore how to manage function arguments in JavaScript by implementing default values for date and conditional shipping charges based on order amount. Understand using rest parameters and spread operators to write flexible code. Practice fixing parameter lists and function calls to achieve desired outputs in a placeOrder function.
We'll cover the following...
We'll cover the following...
Problem statement
In this exercise, you are required to complete the placeOrder() function to get the desired output.
Function description
The placeOrder() function assumes values for shipping and date if those values are not given.
There are two requirements that the function needs to implement:
- The default value of
dateshould