上一页 1 ··· 11 12 13 14 15
摘要: OpenFileDialog of1 = new OpenFileDialog(); if (of1.ShowDialog() == DialogResult.OK) { textBox1.Text = of1.FileName; } FileSt... 阅读全文
posted @ 2012-03-18 16:55 Uoolo 阅读(583) 评论(1) 推荐(1) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace ConsoleApplication4{ class Class1 { int count; int[] list=new int[50]; public void putin() { Console.Write("请输入你的数组元素,以空格隔开,以回车结束:"); string str = Console.ReadLine(); string[] result = str.Split( 阅读全文
posted @ 2011-08-31 15:26 Uoolo 阅读(253) 评论(0) 推荐(0) 编辑
摘要: using System; using System.IO; public class Chapter4 { static void Main() { int[] numbers = new int[100];FileStream f1 = new FileStream(@"c:\numbers.txt",FileMode.Open);StreamWriter s1 = new StreamWriter(f1);Random r1 = new Random(); for (int j = 0; j < 100; j++){ s1.WriteLine( r1.Next( 阅读全文
posted @ 2011-08-30 11:29 Uoolo 阅读(187) 评论(0) 推荐(0) 编辑
摘要: System.Diagnostics.Stopwatch stopwatch = new Stopwatch(); stopwatch.Start(); // 开始监视代码运行时间 // you code .... stopwatch.Stop(); // 停止监视 TimeSpan timespan = stopwatch.Elapsed; // 获取当前实例测量得出的总时间 double hours = timespan.TotalHours; // 总小时 double minutes = timespan.TotalMinutes; // 总分钟 double seconds = t. 阅读全文
posted @ 2011-08-30 11:19 Uoolo 阅读(173) 评论(0) 推荐(1) 编辑
上一页 1 ··· 11 12 13 14 15