public boolean lessThan (Card c)
  {
    if (c==null || c.rank==null || rank == null)
      return false;
    if (rank.lessThan (c.rank))
      return true;
    if (rank.greaterThan (c.rank))
      return false;
    if (c.suit == null || suit == null)
      return false;
    if (suit.lessThan (c.suit))
      return true;
    if (suit.greaterThan (c.suit))
      return false;
    
    // shouldn't reach here normally
    System.err.println ("identical card");
    return false;
  }