CreditOrganizer.cpp
上传用户:sz0451
上传日期:2022-07-29
资源大小:256k
文件大小:1k
- // This is the main project file for VC++ application project
- // generated using an Application Wizard.
- #include "stdafx.h"
- #include "CreditCardAccount.h"
- #using <mscorlib.dll>
- using namespace System;
- // This is the entry point for this application
- #ifdef _UNICODE
- int wmain(void)
- #else
- int main(void)
- #endif
- {
- Console::WriteLine("Creating account object");
- CreditCardAccount * account1;
- account1 = new CreditCardAccount(12345, 2000);
- Console::WriteLine("nMaking a purchase (300)");
- account1->MakePurchase(300);
- Console::WriteLine("nMaking a purchase (700)");
- account1->MakePurchase(700);
- Console::WriteLine("nMaking a purchase (500)");
- account1->MakePurchase(500);
- Console::WriteLine("nRedeeming points");
- account1->RedeemLoyaltyPoints();
- Console::WriteLine("nDeleting account object");
- delete account1;
-
- return 0;
- }