标签:
package com.hanqi; import java.util.*; public class zuoyeduizhezhi { public static void main(String[] args) {//纸张对折超过山峰高度 double a=0.08; double b=884813*10; for(int zds=1;zds<=99;zds++) { a=a*2; if(a>b) { System.out.println(zds); break; } } //阶层每阶\1 a=1; b=1; double c=0; while(a<=20) { b=a*b; a++; c=c+1/b; }System.out.println(c); } }
标签:
原文地址:http://www.cnblogs.com/zzyu/p/5480599.html