摘要: 题意是求七段数码管的显示,可将显示分为五个部分,垂直方向三个,水平方向两个;最后再求五个部分的组合。。。。好麻烦呐,不过思路简单,可能模拟题都这样吧。。。。View Code 1 #include<stdio.h> 2 #include<stdlib.h> 3 #include<math.h> 4 #include<string.h> 5 6 void printv1(int s,int a) 7 { 8 int i; 9 printf(" "); 10 switch(a) 11 { 12 case 1: case 4: 13 阅读全文
posted @ 2012-08-28 23:09 zhongya 阅读(240) 评论(0) 推荐(0) 编辑
摘要: View Code 1 #include<stdio.h> 2 #include<stdlib.h> 3 #include<string.h> 4 #include<math.h> 5 6 7 int main() 8 { 9 int i, t, j, m, ncases;10 int num, k, flag,a[18];11 12 while(scanf("%d",&num) != EOF)13 {14 if(num == 0) break;15 flag = 0;16 for(i=2; i<=16; ... 阅读全文
posted @ 2012-08-28 23:05 zhongya 阅读(218) 评论(0) 推荐(0) 编辑