public static void main(String[] args) {
int lastNum=1000;
BigInteger res = new BigInteger("1");
for(int i=1;i<=lastNum;i++) {
res = res.multiply(new BigInteger(String.valueOf(i)));
}
String s=res.toString();
System.out.println(lastNum+"!的结果是:");
System.out.println(s);
int count=0;
for (int i = 0; i < s.length(); i++) {
if(s.charAt(i)=='0') count++;
}
System.out.println("结果中共有"+count+"个0");