多对一 关联映射 --- many-to-one 场景:用户和组;从用户角度来,多个用户属于一个组(多对一 关联) 使用hibernate开发的思路:先建立对象模型(领域模型),把实体抽取出来。 目前两个实体:用户和组两个实体,多个用户属于一个组,那么一个用户都会对应于一个组,所以用户实体中应该有一...
分类:
系统相关 时间:
2014-07-02 20:42:17
阅读次数:
387
Mergeksorted linked lists and return it as one sorted list. Analyze and describe its complexity.合并k个排序列表解题思路是:取出 k个元素进行堆排序,每次取出最小的元素,插入链表中即可注意本题利用了c++...
分类:
其他好文 时间:
2014-07-02 20:16:54
阅读次数:
273
Reverse a linked list from position m to n. Do it in-place and in one-pass.
分类:
其他好文 时间:
2014-07-02 20:12:57
阅读次数:
182
题比较容易读懂,但是建模需动点脑子:
一个子串加常数形成的子串认为跟子串相同,求最长不重叠重复子串
题目中说
is disjoint from (i.e., non-overlapping with) at least one of its other appearance(s)
意味着不能重叠,举个例子
1, 2,3, 52, 53,54
1,2, 3和 52, 5...
分类:
其他好文 时间:
2014-07-02 15:15:01
阅读次数:
289
http://ionicframework.com/blog/angularjs-console/1: Access ScopesWe can access any scope (even isolated ones!) on the page with a simple JS one-liner:...
分类:
Web程序 时间:
2014-07-02 14:53:37
阅读次数:
443
The gray code is a binary numeral system where two successive values differ in only one bit.
分类:
其他好文 时间:
2014-07-02 14:47:43
阅读次数:
253
The Story:Last week, I found one of our embedded arm linux device ran out of flash space( totally only 128M for apps and OS).After checking for a whil...
分类:
其他好文 时间:
2014-07-02 14:30:13
阅读次数:
317
转自:http://robert.penz.name/658/howto-access-mtp-devices-via-usb-on-ubuntu-12-04/ A friend asked me how he can access his Nexus 7 device via USB on hi....
分类:
其他好文 时间:
2014-07-02 13:51:19
阅读次数:
289
ERROR 1665 (HY000): Cannot executestatement: impossible to write to binary log since BINLOG_FORMAT = STATEMENTand at least one table uses a storage engine limited to row-based logging.InnoDB is limited to row-logging when transaction isolation level is REA...
分类:
数据库 时间:
2014-07-02 07:46:46
阅读次数:
322
在现有类和结构体的类型基础上,扩展新的功能。 语法:extension SomeType{// new functionality to add to SomeType goes here}An extension can extend an existing type to make itadopt one or more protocols.Where this is the case,the...
分类:
其他好文 时间:
2014-07-02 07:36:22
阅读次数:
244