标签:
> 分析
#include "stdio.h" int main(void) { float len = 0.0 ; int count = 0 ; while(1) { scanf("%f", &len) ; if(len == 0.00) break ; count = 0 ; while(len > 0) { count++ ; len -= (float)1 / (count+1) ; } printf("%d card(s)\r\n", count) ; } return 0 ; }
标签:
原文地址:http://www.cnblogs.com/codesworld/p/4703285.html