public static long recursion(String s, int i, int forrige) {
		if (i == -1) {
			Set<Character> set = new HashSet<Character>();
			for (int j = 0; j < s.length(); j++) {
				set.add(s.charAt(j));
			}
			return set.size()==9?Long.parseLong(s):0;
		}
		int tall = 0;
		long sum = 0;
		while (Math.log10(tall+=primes.get(i)) < 3) {
			if (tall%100==forrige/10)
				if (i <= 1 || (mod100[i-1].contains(tall/10)) && (i<=2 ||mod10[i-2].contains(tall/100)))
					sum+=recursion(tall/100+s, i-1, tall);
				
		}
		return sum;
	}