Beispiel #1
0
        public bool sosMenor(I_Comparable comparable)
        {
            Type tipo = comparable.GetType();
            Type obj  = this.GetType();

            if (tipo.Equals(obj))
            {
                return(Valor < ((Carta)comparable).Valor && PesoSimbolo < ((Carta)comparable).PesoSimbolo ? true : false);
            }
            return(false);
        }
Beispiel #2
0
        public bool sosIgual(I_Comparable comparable)
        {
            Type tipo = comparable.GetType();
            Type obj  = this.GetType();

            if (tipo.Equals(obj))
            {
                return(Valor.Equals(((Carta)comparable).Valor) && PesoSimbolo.Equals(((Carta)comparable).PesoSimbolo) ? true: false);
            }
            return(false);
        }