/// <summary> /// LunDay 的摘要说明。 /// 用法说明 /// 直接调用即可,比较简单 /// </summary> public class LunDay { public LunDay() { // // TODO: 在此处添加构造函数逻辑 // } //天干 private static string[] TianGan = { "甲", "乙", "丙", "丁"
ToUpper().Substring(8, 0x10); return (softname + "C" + cpuID); } if (bIOSSerialNumber != "") { MD5 md2
C#判断指定分区是否是ntfs格式 using System; using System.IO; namespace RobvanderWoude { class IsNTFS { public static
watcher = new FileSystemWatcher(); watcher.Path = @"c:\mydir"; // Register for events watcher.Created +=
C#导出数据到Excel文件 ///
C#对集合类进行快速排序 ///
FileStream aFile = new FileStream(SingleFile, FileMode.Open); StreamReader sr = new StreamReader(aFile, Encoding.GetEncoding("gb2312"), true); string FileContent = sr.ReadToEnd(); aFile.Close(); Proce
插入排序法-c# 这个算法的逻辑 1、第一个元素可以看做是已经排序好的小数组,第二个元素和这个小数组比较,放到合适的位置,组成新的已排序的小组数。 2、第三个元素在和前面组成的新的小数组比
C#编写的FTP上传简单工具类 using System; using System.Net; using System.IO; using System.Text; using System.Net
读取方式: 逐词读取, 词之间用空格区分,遇到"."就停止读取,返回的内容存取在vector<string>中 //read data from the file, Word By Word //when used in this manner, we'll get space-delimited bits of text from the file //but all of the whites
C语言模仿wget的进度条效果 #include
合并两个数组中的元素到整型数组c,要求去除重复元素并保持c有序(非降序)。 例子如下: a = 2,3,4,6,8,9 b = 7,9,10 c = 2,3,4,6,7,8,9,10
// // Created by liujan on 10/24/14. // Copyright (c) 2014 liujan. All rights reserved. // #include
// // Created by liujan on 10/24/14. // Copyright (c) 2014 liujan. All rights reserved. // #include
// // Created by liujan on 10/21/14. // Copyright (c) 2014 liujan. All rights reserved. // #include
visit[200]; void DFS(int c) { a[0]=1;// 初始为1 if(c==n&&!su[a[0]+a[n-1]])// 如果 c==n 则结束 如果 第一个与最后一个和也为素数
4R5qEjw8jn0X67QG M8mJJlAIuEUhtPQNC4QOa RC4 应用代码: public static void Main(string[] args) { string
比如说,现在有4个数据需要传输,分别为A、B、C、D,所以一般来说,如果此时没有考虑四个数据出现的概率,那么我们完全可以这么分配,平均长度为2, /* * A - 00 B - 01 * C - 10 D - 11 */
move (char A,int n,char C) { m++; printf("step%d:Move%d,From %c To %c\n",m,n,A,C); } void Hanoi(int n,char
#include <iostream> using namespace std; //实现一个函数求字符串的长度。 int my_length(const char *s) { if (*s == '\0')return 0; else return 1+my_length(s + 1); } int main() { char *s = "123456"; cout << my_length(s