11. Tutorial: Making Change
Tutorial: Making Change
Now, you're ready to deploy a more complex Function as a Service. The next tutorial will be all about event-handling for a function that automatically makes the smallest amount of change given an input amount of US currency. For example, given $0.63, the function should output: 2 quarters, 1 dime, 3 pennies.
It's suggested that you copy this tutorial code into your Cloud9 environment in a different, working tab so you can interact with and test the code as you go through the instructional videos in this tab. This way you can toggle between learning new skills and applying new skills.
To copy this code, you have two options:
Instructions
- Write a test event, passing in some $
amountas a request to your function, and view the JSON response
This is a tutorial, meant to be demonstrative and educational; you do not need to modify any code, here.