2013年11月21日
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace 斐波那契数列{ class Program { /// /// 采用递归的方法求斐波那契数列的第15项的数值 /// /// static void Main(string[] args) { Console.WriteLine("请输入要输出斐波那契数列哪一项的数值:"); int number = Convert.ToInt32(Console... 阅读全文
posted @ 2013-11-21 10:55 相约看日出 阅读(1218) 评论(0) 推荐(0) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace 冒泡排序{ class Program { /// /// 冒泡排序,给定一组数据1,12,23,8,5,20,按照倒序排序(从大到小) /// /// static void Main(string[] args) { int[] sums = { 1, 12, 23, 8, 5, 20 }; for (int i = 0; i < sums.L... 阅读全文
posted @ 2013-11-21 10:51 相约看日出 阅读(1918) 评论(0) 推荐(0) 编辑