@SuppressWarnings("unchecked")
	public final K[] decode(final String crypt) {
		ArrayList<K> plain = new ArrayList<K>();
		String code = "";
		for (final Character c : crypt.toCharArray()) {
			code += c;
			K symbol = this.codes.get(code);
			if (symbol!=null) {
				plain.add(symbol);
				code = "";
			}
		}
		return (K[]) plain.toArray();
	}