public int getChar(String code){
		HuffNode p = root;
		for(int i = 0; p!=null && i < code.length(); i++)
			if(code.charAt(i) == '0')
				p = p.left;
			else
				p = p.right;
		
		if(p == null)
			return ERROR;
		
		return p.value;
	}