using System;using System.Collections.Generic;using
System.Linq;using System.Text;using System.Windows.Forms;namespace Common{ ///
/// TextBox控...
分类:
其他好文 时间:
2014-05-08 19:15:06
阅读次数:
293
Linq给我们带来了很多的便利,不必时时刻刻写sql,可以让一个不懂T-SQL的程序猿也能实现简单编程,但是linq在效率上确实比不上SQL。数据量越大,效率问题就明显。一般查询可以这样写var
v = (from c in en.T_AQI wher...
分类:
其他好文 时间:
2014-05-08 18:34:22
阅读次数:
266
在更新上面一道题的时候我就想,是不是还有一道打印路径的,果不其然啊。
这种题非常常见的,做法也很简单,我是用一个引用的vector来存,满足条件之后直接压入结果集中,当然也可以用数组之类的,都一样。用引用需要注意的问题就是递归进行到后面的时候会对栈中的上层状态产生影响,当然可以用传值的方法来避免这个问题,但是那样子开销太大了(每次船建和销毁一个类对象,不是明智的选择)。那么就是要回退,那什么时候...
分类:
其他好文 时间:
2014-05-08 11:03:31
阅读次数:
248
写题解之前首先要感谢妹子。
比较容易的斜率DP,设sum[i]=Σb[j],sum_[i]=Σb[j]*j,w[i]为第i个建立,前i个的代价。 那么就可以转移了。
备注:还是要感谢妹子。/**************************************************...
分类:
其他好文 时间:
2014-05-08 10:24:20
阅读次数:
260
一次通过: 1 public class Solution { 2 public int
romanToInt(String s) { 3 int sum = 0; 4 int[] num = new int[s.length()]; 5 if...
分类:
其他好文 时间:
2014-05-08 08:24:26
阅读次数:
233
最近碰到客户的一个需求。使用交叉表来显示客户数据。也就是以同时以行头和列头交叉形式显示数据内容。同时要求即使有些列没有数据,也需要显示该列内容,并设置默认值。说明:
“交叉表”对象是一个网格,用来根据指定的条件返回值。数据显示在压缩行和列中。这种格式易于比较数据并辨别其趋势。它由三个元素组成: 行 ...
分类:
其他好文 时间:
2014-05-08 07:53:42
阅读次数:
387
using System;using
System.Collections.Generic;using System.Linq;using System.Text;using
System.Data;using System.Drawing;using System.IO;using System....
分类:
其他好文 时间:
2014-05-08 06:10:59
阅读次数:
395
问题描述
给定(可能是负的)整数序列A1, A2,...,AN, 寻找(并标识)使Sum(Ak)(k >=i, k <= j)的值最大的序列。如果所有的整数都是负的,那么连续子序列的最大和是零。...
分类:
其他好文 时间:
2014-05-08 01:49:14
阅读次数:
273
链接:http://poj.org/problem?id=1775
Description
John von Neumann, b. Dec. 28, 1903, d. Feb. 8, 1957, was a Hungarian-American mathematician who made important contributions to the foundations of m...
分类:
其他好文 时间:
2014-05-07 23:57:32
阅读次数:
402
简单:e sum of the squares of the first ten natural
numbers is,12 + 22 + ... + 102 = 385The square of the sum of the first ten
natural numbers is,(1 + 2 ...
分类:
其他好文 时间:
2014-05-07 20:23:43
阅读次数:
338