private int getLevenshteinDistance(String s, String t) {
		if (s == null || t == null) {
			throw new IllegalArgumentException("Can not deal with null strings");
		}

		if (s.length() == 0) return t.length();		
		if (t.length() == 0) return s.length();

		int n = s.length();
		int m = t.length();
		int d[][] = new int[n + 1][m + 1];
		
		int cost;

		// matrix initialization
		for (int i = 0; i <= n; i++) d[i][0] = i;

		for (int j = 0; j <= m; j++) d[0][j] = j;


		for (int i = 1; i <= n; i++) {
			char v = s.charAt(i - 1);

			for (int j = 1; j <= m; j++) {
				char w = t.charAt(j - 1);
				
				if (v == w) {
					cost = 0;
				} else {
					cost = 1;
				}

				d[i][j] = Math.min(Math.min(d[i - 1][j] + 1, d[i][j - 1] + 1), d[i - 1][j - 1]	+ cost);
			}
		}
		return d[n][m];
	}