# Fibonacci数列的计算和转换

#include #define N 30 int i=0; int a[N]; int fun(int first, int second, int num) { int temp; a[i] = first; a[i+1] = second; while(num --) { ++i; a[i+1] = a[i-1] + ...

# 字符串反向输出

#include #include #define N 100 int main() { char a[N], b[N]; int len, i = 0; scanf("%s", a); len = strlen(a); b[len] = '\0'; while(len--) { b[i] = a[len]; ...

# Rightmost Digit

#include int fun(a){ int c, n; c = a%10; switch(c) { case 0: case 1: case 5: case 6: case 9: n = c; break; case...

#include int main() { int Y, N, M; scanf("%d", &M); while(M--) { scanf("%d %d", &Y, &N); if(N10000) break; if(!((Y%4 == 0)&&(Y%100 != 0) || (Y%400 == 0)))...

# Box of Bricks

#includeint main(){ int M, num, m, j=1; int a[51]; int i, avg; while((scanf("%d", &M)!= EOF) && M) { num = 0; m = 0; for(i=0; i<M; i++){ scanf("%d", &a[i]); m += a[i]; } avg = m/M; for(i=0; i avg) num...

# poj.org pro 1003 hangover

/*poj.org pro 1003 author: bubble date: 2013-7-15 */ #include int main(){ double sum; int n; double len; while(scanf("%lf",&sum)!=EOF&&sum!=0.00){    n=1;         len=0.00;         do{...

# poj.org Pro 1004

/* poj.org problem 1004 finacial management author: bubble date: 2013-7-15 */ #include int main(){     float a[12],m=0.0,n=0.0;     int i;     for(i=0;i         scanf("%f",&a[i]);         n=...

个人资料
• 访问：4009次
• 积分：174
• 等级：
• 排名：千里之外
• 原创：14篇
• 转载：0篇
• 译文：0篇
• 评论：0条
文章分类
文章存档
评论排行