摘要:A binary tree is defined as a tree where each node can have no more than two children.Building a Binary Search Tree:首先创建一个节点Class public class BtNo...
阅读全文
11 2015 档案
摘要:A abstract class An abstract class is a class that must be inherited and have the methods overridden. It can not be instantiated. And at least one of
阅读全文
摘要:1. Convert string from "AAABBCC" to "A3B2C2". 当面试者提出这个问题的时候,首先需要确认题意:譬如:字符串是不是顺序的,是否有字符重复出现。 例如: ABBAACB , AAABBCCCBBAA。 如果是顺序的话可以一次遍历字符,如果是杂序的话,需要2次遍
阅读全文
摘要:这个是非常基本的一道面试题,但是要考虑周全。首先反转一个字符串:基本思路是变成Char数组,然后调用C#里面的方法,或者设定两个index,从头,尾向中间遍历,并交换。方法一: Array.Reverse(char *). 注意在开始的时候要判断字符串为null或空。 public s...
阅读全文
摘要:(Note: Most are collected from Internet. 绝大部分内容来自互联网)1. What's the difference between Hashtable and Dictionary?Hashtable and Dictionary are collection...
阅读全文
摘要:基本上在面试的时候,会具体到两个int数组,或string数组。具体也就是讨论算法。首先需要的是和面试的人确认题目的含义,并非直接答题。然后,可以提出自己的想法,首先最快的是用linq { List array0 = new List() { 1, 2, 9, 3...
阅读全文