Spot the Bug

Sunday, February 10th, 2008

A future exam question: Identify the elementary programming error in the following actual output from a real web store.

Bonus credit: describe both the quick emergency fix for the problem, and the longterm fix for the problem.

Greetings from CellularFactory.com.

We thought you'd like to know that we shipped your items, and that this completes 
your order. Your order number is ###### Please keep this number for any future 
requests

You can track the status of this order, and all your orders, online by visiting our 
page at http://www.CellularFactory.com/help/shipping.jsp

The following items have been shipped to you by CellularFactory.com:
---------------------------------------------------------------------
Qty      Item                   Price       Shipped      Subtotal
---------------------------------------------------------------------
1      Travel Charger                   5.89      2008-02-09      5.89
---------------------------------------------------------------------

Shipped via USPS (estimated arrival date: about 4-6 days after)
---------------------------------------------------------------------
Item Subtotal
5.89
Shipping & Handling:
3.99
Total:
9.879999999999999
--------------------------------------------------------------------

This shipment was sent to:

(more…)