Added explanatory comments to the client app code.