#includeint main(){ int a[50],i,j,t,n; //scanf("%d%d%d%d%d",&a,&b,&c,&d,&e); printf("\n input number of date:"); scanf("%d",&n); printf("input %d munb...
分类:
其他好文 时间:
2015-04-15 21:16:56
阅读次数:
120
class Program { struct player { public string name; public int hp; public int gj; public ...
分类:
其他好文 时间:
2015-04-15 21:16:00
阅读次数:
133
namespace ConsoleApplication1{ class Program { static void Main(string[] args) { int a = 1; int coun...
分类:
其他好文 时间:
2015-04-15 21:08:54
阅读次数:
83
Counting bits set (naive way)unsigned int v; // count the number of bits set in vunsigned int c; // c accumulates the total bits set in vfor (c = 0; v...
分类:
其他好文 时间:
2015-04-15 21:07:12
阅读次数:
256
#includeint main(){int n,m,a,b,c;printf("请输入分子和分母:\n");scanf("%d%d",&n,&m);a=n;b=m;if(n>m){do{c=a%b;a=b;b=c;}while(c!=0);n=n/a; m=m/a;} else{ do{c=b%a...
分类:
其他好文 时间:
2015-04-15 21:06:25
阅读次数:
90
冒泡排序思想很容易理解:比较数组中相邻的两个数据,如果前面的数据比后面的数据大,就将两个数据进行交换,每循环一次,最大的数据就会被转移到最后一位。算法一实现:#includevoid Swap(int &a , int &b) { a = a ^ b ; b = a ^ b ; ...
分类:
编程语言 时间:
2015-04-15 21:05:18
阅读次数:
149
class Program { private static void ditu(int[, ,] dt, int i) { for (int j = 0; j < 10; j++) { f...
分类:
其他好文 时间:
2015-04-15 21:04:35
阅读次数:
112
class MyView extends View { float phase; PathEffect[] effects = new PathEffect[7]; int[] colors; private Paint paint; Path path; pub...
分类:
移动开发 时间:
2015-04-15 21:01:39
阅读次数:
152
选择排序的思想也比较容易理解,用一个变量控制数组的有序区和无序区,从无序区中挑选一个最小的数放到有序区的末尾,直到把无序区数据挑完为止,相关代码如下:#includevoid Swap(int &a , int &b) { a = a ^ b ; b = a ^ b ; a ...
分类:
编程语言 时间:
2015-04-15 20:57:24
阅读次数:
132
求大神告诉我哪里错了奇偶数分离时间限制:3000ms | 内存限制:65535KB难度:1描述有一个整型偶数n(2#includeint main(){int n,i=1;scanf("%d",&n);for(i=1;i<=n;){printf("%d ",i);i=i+2;}printf("\n"...
分类:
其他好文 时间:
2015-04-15 20:54:06
阅读次数:
109