题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1062解题报告:注意一行的末尾可能是空格,还有记得getchar()吃回车符。 1 #include 2 #include 3 #include 4 #include 5 #include 6 #incl...
分类:
其他好文 时间:
2014-07-27 10:12:02
阅读次数:
149
Reverse Words in a String考虑几个特殊的情况1.若字符窜s=" "2.字符窜s=“a b d e”3.字符窜s=“ a”class Solution {public: void reverseWords(string &s) { int i; int c...
分类:
其他好文 时间:
2014-07-26 17:03:01
阅读次数:
360
[cpp] view plaincopytemplatevoidreverse(BidirectionalIteratorfirst,BidirectionalIteratorlast);[cpp] view plaincopy如果不是改变原来的容器,而是翻转之后放在新容器里面,直接用reverse...
分类:
编程语言 时间:
2014-07-26 16:59:21
阅读次数:
394
想把一些对象的距离关系显示在图上,对象特征是很多维的,而显示通常用二维平面或三维立体图。于是先用PCA将特征降成两维,然后两维分别作横轴和纵轴。这里PCA用的MATLAB降维工具箱drtoolbox,这样在平面上的一个关系就可以显示出来了。mappedX = compute_mapping(X, 'PCA', 1); 另外每个对象还有个相应的值,相当于还有一维信息想表示出来。除了用三维图,也可以...
分类:
其他好文 时间:
2014-07-26 15:07:10
阅读次数:
239
参考链接:http://blog.163.com/hero_213/blog/static/398912142010312024809近年来ORM(Object-Relational Mapping)对象关系映射,即实体对象和数据库表的映射)技术市场人声音鼎沸,异常热闹, Sun在充分吸收现有的优秀...
分类:
系统相关 时间:
2014-07-26 14:52:40
阅读次数:
295
今天用python自带的sorted对一个列表进行排序, 在这里总结一下只要是可迭代对象都可以用sorted 。sorted(itrearble, cmp=None, key=None, reverse=False)=号后面是默认值 默认是升序排序的, 如果想让结果降序排列,用reverse=Tru...
分类:
编程语言 时间:
2014-07-26 14:49:40
阅读次数:
284
题目:Evaluate the value of an arithmetic expression in Reverse Polish Notation.Valid operators are +, -, *, /. Each operand may be an integer or anothe....
分类:
编程语言 时间:
2014-07-26 14:14:35
阅读次数:
225
I could also have called this "wildcard .NET mapping in IIS Express from web.config."I'm sure that, like, everyone out there but me has figured this o...
分类:
其他好文 时间:
2014-07-26 13:58:34
阅读次数:
239
Reverse digits of an integer.Example1:x = 123, return 321Example2:x = -123, return -321 1 class Solution { 2 public: 3 int reverse(int x){ 4 ...
分类:
其他好文 时间:
2014-07-26 13:54:24
阅读次数:
206
先建立一个模型123456789101112array("mapping_type"=>MANY_TO_MANY,"foreign_key"=>"uid",//中间表的字段"relation_foreign_key"=>"gid",//中间表的字段"relation_table"=>"think_u...
分类:
Web程序 时间:
2014-07-26 13:50:15
阅读次数:
236