F[a][b][c]=F[a-1][b][c]+F[a][b-1][c]+F[a][b][c-1];
a>=b>=c;
package zzz; import java.math.BigInteger; import java.util.Scanner; public class Main { public static void main(String args[]){ Scanner cin=new Scanner(System.in); BigInteger a[][][]=new BigInteger[67][76][76]; a[0][0][0]=BigInteger.ONE; for(int i=1;i<=60;i++) for(int j=0;j<=i;j++){ for(int k=0;k<=j;k++){ a[i][j][k]=BigInteger.valueOf(0); if(i>j) ///三个条件是并行的 a[i][j][k]=a[i][j][k].add(a[i-1][j][k]); if(j>k) a[i][j][k]=a[i][j][k].add(a[i][j-1][k]); if(k>=1) a[i][j][k]=a[i][j][k].add(a[i][j][k-1]); //System.out.println(a[i][j][k]); } } while(cin.hasNext()){ int n=cin.nextInt(); System.out.println(a[n][n][n]); System.out.println(); } } }