// This program tests the class Purchase

class A5Q1
{
   public static void main (String[] args) 
   { 
    // DATA DECLARATIONS
       Client larry, grace;
         

    // IDENTIFICATION
       System.out.println("Question 1: Test of the class Client");
       System.out.println();

    // ALGORITHM BODY
       // Create some users and items
       larry  = new Client("Larry O'Brien", "larry@obrien.ca", "Noël");
       grace  = new Client("Grace Hopper", "grace@coldmail.org", "Informatique");
      

     
       System.out.println("The first client is: " + larry.getName() 
                           + ". His credit is " + larry.getCredit() + "$.");
       System.out.println("The second client is: " + grace.getName() 
                           + ". Her credit is " + grace.getCredit() + "$.");
       
       if (grace.changePassword("Informatique", "ITI")) 
        {
         System.out.println("The password was changed.");
        }
        else
        {
          System.out.println("The password was not changed."); 
        }
        
        if (larry.changePassword("xmas", "NewYear")) 
        {
         System.out.println("The password was changed.");
        }
        else
        {
          System.out.println("The password was not changed."); 
        }
   }
}
