private static BigInteger f(int i, int j) {
		if( i >= m.length || j >= m.length ) 
			return BigInteger.ZERO;
		if(mem[i][j] != null ) 
			return mem[i][j];
		if( m[i][j] == '#' ) 
			return mem[i][j] = BigInteger.ZERO;
		if( i == m.length-1 && j == m.length-1 ){
			return (m[i][j] == '#') ? (mem[i][j] = BigInteger.ZERO): (mem[i][j] = BigInteger.ONE) ;
		}
		return mem[i][j] = f(i+1,j).add(f(i,j+1));
	}