Ejemplo n.º 1
0
 //
 ///
 ////
 /////First menu to choose actions from
 public static void Main(string[] args)
 {
     BankAccounts accounts = new BankAccounts();
     accounts.Create();
     GetAccountInformation(accounts);
     var eventLog = new List<Log>();
     WriteLine("Welcome to Unsecured Bank system!");
     while (true)
     {
         WriteLine("1. Register new account.");
         WriteLine("2. Login with existing account.");
         WriteLine("3. Exit system");
         switch (ReadInt())
         {
             case 1:
                 Registration(accounts, eventLog);
                 Clear();
                 break;
             case 2:
                 Login(accounts, eventLog);
                 Clear();
                 break;
             case 3:
                 Exit(accounts, eventLog);
                 Clear();
                 break;
             default:
                 Write("Wrong input! Please enter a number: ");
                 Read();
                 Clear();
                 break;
         }
     }
 }