The Ada Program: card_package.adb

  1 with Ada, Ada.Text_IO, Ada.Integer_Text_IO;
  2 use Ada;
  3 
  4 package body Card_Package is
  5 
  6    package Suit_IO is new Text_IO.Enumeration_IO (Suit_Type);
  7    package Count_IO is new Text_IO.Integer_IO (Count_Type);
  8 
  9    procedure Put (Item: in Card_Type) is
 10    begin
 11       Text_IO.Put ('(');
 12       Suit_IO.Put (Item.Suit);
 13       Text_IO.Put (',');
 14       Count_IO.Put (Item.Count, Width=>2);
 15       Text_IO.Put (')');
 16    end Put;
 17 
 18 end Card_Package;