lab_riddles/assessment.md

852 B

Riddles Lab Assessment

Pat,

Everything looks good!

Regarding your reflection on GET and POST requests in e-commerce:

  1. The "shopping cart" interface on an online store might be a series of requests from the user to go to product pages and add items to cart. Part of the response would be an update to the shopping cart and on something like Amazon, the indicator in the corner telling you how many items are currently in your cart. I feel like the product page would bet a GET and adding an item to cart would be a POST?

This sounds right. One helpful way of thinking is that GET requests should not cause any changes, while POST requests should cause some kind of change. Therefore, it's safe to re-issue the same GET request over and over (e.g. reloading a webpage) but the same is not true of POST requests.