原创 (C#)字符串反轉

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 {

原创 (C#)計算字符串排列組合數 如"abcd"組合數爲24 "aabb"組合數爲6

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 {

原创 (C#)10進制轉2進制 數字1的個數

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 {

原创 (C#)冒泡排序 Bubble Sort

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Sort { class Bubbl

原创 (C#)重寫分隔符分割字符串 - string.Split(char[] separator)

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 {

原创 (C#) WinForm SendKeys 代碼表

使用 SendKeys 將鍵擊和組合鍵擊發送到活動應用程序。此類無法實例化。若要發送一個鍵擊給某個類並立即繼續程序流,請使用 Send。若要等待鍵擊啓動的任何進程,請使用 SendWait。 每個鍵都由一個或多個字符表示。若要指定單個鍵盤

原创 (C#)排序算法 Sort Algorithm

Sorting algorithm http://en.wikipedia.org/wiki/Sort_algorithm 1.    Bubble Sort http://en.wikipedia.org/wiki/Bubble_so

原创 (C#)單詞反轉 位置不變 e.g., Welcome to my blog! -> emocleW ot ym !golb

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 {

原创 (C#)有一個10階的樓梯 他有幾種方式上去?("一次上一階"和"一次上兩階")

/* * 一個人上樓梯 可以有兩種方式 ‘一次上一階’和‘一次上兩階’ * 問題: 有一個10階的樓梯 他有幾種方式上去? * 補充: 如果樓梯是1階,他有一種上法(一次上一階);如果樓梯是兩階他有2中上法(一次上一階

原创 (C#)打印蛇形正方形矩陣

/* * (C#)打印蛇形正方形矩陣, 如: * 1 2 3 * 8 9 4 * 7 6 5 */ using System; using System.Collections.Generic; using Sys

原创 (C#)漢諾塔

/* 當n=1時,將第一個圓盤由A柱移動到C柱,完成移動 當n>1時,移動方法如下: 1.將1至n-1個圓盤由A移動到B柱 2.將第n個圓盤由A柱移動到C柱

原创 解讀微軟SDET(Software Development Engineer in Test)

以下內容轉自:http://zhidao.baidu.com/question/156694209.html 關於微軟SDET職位,是一個很有爭議的話題。 我不想說SDET多麼多麼好,也不想說它多麼糟,這裏我以一個微軟(總部)SDET

原创 (C#)一道看似簡單卻很難答得完全正確的關於多態的問題

/*關於virtual,overried,new在方法和屬性上以this,base形式輸出的問題 *問主程序的輸出是什麼 */ using System; using System.Collections.Generic; usin

原创 2個堆棧實現自定義隊列的入隊出隊方法 - 調用者定義2個棧的容量

using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace MyQueue { public c

原创 (C#)設計模式 之 單例模式

轉自:http://www.cnblogs.com/xun126/archive/2011/03/09/1970807.html   最近在學設計模式,學到創建型模式的時候,碰到單例模式(或叫單件模式),現在整理一下筆記。   在《Des