public String toString() {
        if (length == 0) {
            return "code has no bits yet";
        }
        
        String str = "";
        for (int i = length - 1; i >= 0; i--) {
            str += getBit(i);
        }
        return str;
    }