@Override
    public boolean equals(Object obj) {
        
        Boolean totuus = false;
       
        
        if (obj instanceof OstosLista)
        {
            OstosLista toinen = (OstosLista)obj;
            if (this.size() <= toinen.size())
            {
                OstosLista tmp = new OstosLista(this);
                for (int i = 0; i < toinen.size(); i++) {
                    for (int j = 0; j < tmp.size(); j++) {
                        Object a = toinen.get(i);
                        Object b = tmp.get(j);
                     //   System.out.println("a: " + a);
                      //  System.out.println("b: " + b);
                        if (a.equals(b))
                        {
                            tmp.remove(a);
                        }
                        
                    }
                    
                }
                if (tmp.isEmpty())
                {
                    totuus = true;
                }
            }
            return totuus;
        }
        else
        {
            return totuus;
        }
            
    }