原创 關於C#的virtual,Override和new的坑
先看這麼一段代碼: public class Base { public virtual void DoWork( int a) { Console.WriteLine( "base dowork")
原创 是愛情,讓我們直立行走
你來自北京周口, 我來自雲南元謀。 牽着你毛茸茸的小手, 輕輕地親上一口。 是愛情, 讓我們直立行走。
原创 比爾蓋茨給年輕人的14條建議
Some rules kids won't learn in school Text By Cha
原创 用Irony實現一個計算器附上源碼
滿足的功能如下: 加減乘除四則運算括號優先級 比如: 3+2*4 - 8/4 的結果是9 2* (2 + 3) - 2的結果是8 Irony是.net平臺下實現語言的開發工具箱。作者把C#這種強大的現代語言引入編譯器解析領域,語法規
原创 LeetCode455. Assign Cookies簡單的做法
Assume you are an awesome parent and want to give your children some cookies. But, you should give each child at most
原创 大數相乘
local bignum = {} function bignum.len(num) return string.len(num) end function bignum.splitAt(num, pos) local
原创 LeetCode 401. Binary Watch
A binary watch has 4 LEDs on the top which represent the hours (0-11), and the 6 LEDs on the bottom represent the min
原创 Leetcode461. Hamming Distance不要太簡單哦
The Hamming distance between two integers is the number of positions at which the corresponding bits are different.
原创 LeetCode476. Number Complement位操作面試題
Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary rep
原创 463. Island Perimeter我的解法
You are given a map in form of a two-dimensional integer grid where 1 represents land and 0 represents water. Grid cell
原创 LeetCode448. Find All Numbers Disappeared in an Array新年第一篇
Given an array of integers where 1 ≤ a[i] ≤ n (n = size of array), some elements appear twice and others appear once
原创 C#編程命名規範
這盛世,如你所願。每當看到一些混蛋的官員言論,內心挺憤怒的,即痛恨這種混蛋,也痛恨自己無能爲力。 命名約定: 在.NET Framework名稱空間中有兩種命名約定,稱爲PascalCase和camelCase在camelCase中,
原创 LeetCode485. Max Consecutive Ones有你真好
Given a binary array, find the maximum number of consecutive 1s in this array. Example 1: Input: [1,1,0,1,1,1] Outpu
原创 大數big number的加減運算
以下是Lua的實現: function plus(str1, str2) local increase = 0 local t = {} local max = math.max(string.len(str1),
原创 LeetCode453. Minimum Moves to Equal Array Elements我是這麼解答的
Given a non-empty integer array of size n, find the minimum number of moves required to make all array elements equal