2015年4月29日
摘要: 递归算法计算阶乘import java.util.Scanner;public class DiGui { static long fact(int n) { if(n<=1) return 1; else return n*fact(n-1); } public static void... 阅读全文
posted @ 2015-04-29 15:44 Mathematics 阅读(247) 评论(0) 推荐(0) 编辑
摘要: import java.util.Scanner;public class DiTui { public static int fibonacci(int n){ int t1,t2; if(n==1||n==2) { return 1; } else { t1 = fibona... 阅读全文
posted @ 2015-04-29 15:21 Mathematics 阅读(231) 评论(0) 推荐(0) 编辑
摘要: 穷举法求解鸡兔同笼问题//穷举法求解鸡兔同笼问题import java.util.Scanner;public class QiongJu { static int chicken,habbit; public static int qiongJu(int head,int foot){ int ... 阅读全文
posted @ 2015-04-29 13:28 Mathematics 阅读(271) 评论(0) 推荐(0) 编辑
摘要: 1.队列定义static final int QUEUELEN=15;class DATA3{ String name; int age;}class SQType{ DATA3[] data = new DATA3[QUEUELEN]; int head; int t... 阅读全文
posted @ 2015-04-29 11:18 Mathematics 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 1.栈的定义static final int MAXLEN=50;class DATA2{ String name; int age;}class StackType{ static final int MAXLEN=50; DATA2[] data = new DATA2[... 阅读全文
posted @ 2015-04-29 10:36 Mathematics 阅读(128) 评论(0) 推荐(0) 编辑
  2015年4月28日
摘要: 1.顺序表的定义static final int MAXLEN=100; //定义顺序表的最大长度class DATA{ String key; //结点的关键字... 阅读全文
posted @ 2015-04-28 14:44 Mathematics 阅读(199) 评论(0) 推荐(0) 编辑
  2015年4月13日
摘要: 1.随机变量2.随机变量函数分布3.二维随机变量Z=f(X,Y)的分布重要的分布 阅读全文
posted @ 2015-04-13 14:23 Mathematics 阅读(245) 评论(0) 推荐(0) 编辑