public static int decodeWays(int[]A) {
		int n=A.length;
		if (n==0||A[0]==0) return 0;
		int[]dp=new int[n+1];dp[0]=dp[1]=1;
		for (int i=2;i<=n;++i)dp[i]=(A[i-1]>0?dp[i-1]:0)+(A[i-2]!=0&&(A[i-2]*10+A[i-1]<=26)?dp[i-2]:0);
		return dp[n];
	}