public void add(String s){
        if(s.equals("Head")){
            m[size++] = "Head";
            countHead();
        }else if(s.equals("Tail")){
            m[size++] = "Tail"; 
            countTail();
        }
    }