【题目】
Given a linked list, remove the nth node from the end of list and return its head.
For example,
Given linked list: 1->2->3->4->5, and n = 2.
After removing the second node from the end, the linked list becomes 1->2->3->5.
Note:
Given n will ...
分类:
其他好文 时间:
2014-05-18 18:48:03
阅读次数:
269
for (int k = 0; k
if (((k + 1) % 2) != 0) {
m1 = (MealEntity) list.get(k);
%>
">
src="mealImg/.jpg" width="148"
height="126" border="0" />
:
原价:人民币元
现价:人民币
元
">
...
分类:
其他好文 时间:
2014-05-18 14:07:40
阅读次数:
234
【题目】
Given a linked list, reverse the nodes of a linked list k at a time and return its modified list.
If the number of nodes is not a multiple of k then left-out nodes in the end should remain as it is.
You may not alter the values in the nodes, only n...
分类:
其他好文 时间:
2014-05-18 10:22:34
阅读次数:
367
【题目】
Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity.
【题意】
合并K个有序链表
【思路】
归并
Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses.
For ...
分类:
其他好文 时间:
2014-05-18 09:05:40
阅读次数:
255
【题目】
Given a linked list, swap every two adjacent nodes and return its head.
For example,
Given 1->2->3->4, you should return the list as 2->1->4->3.
Your algorithm should use only constant space. You may not modify the values in the list, only nodes it...
分类:
其他好文 时间:
2014-05-18 08:37:57
阅读次数:
370
这里并不是系统详细介绍每一个Linux命令,仅仅是记录本人在平时工作中经常用到的一些比较基础的命令及相关的参数,同时用了一些简单的例子来说明这些命令的用途,以及如何用多种命令来实现同一种功能。
1、ls命令
要显示当前目录下的文件列表时,我经常就使用ls命令的以下...
分类:
系统相关 时间:
2014-05-18 08:11:19
阅读次数:
335
文件对象内建方法列表
文件对象的方法
操作
file.close()
关闭文件
file.fileno()
返回文件的描述符(file descriptor,FD,整数值)
file.flush()
刷新文件的内部缓冲区
file.isatty()
判断fil...
分类:
编程语言 时间:
2014-05-18 06:23:28
阅读次数:
197
现在我们来分析一下CAN总线的接收数据流程,对于网络设备,数据接收大体上采用中断+NAPI机制进行数据的接收。同样,我们现在的CAN模块也是采用同样的方式进行数据的接收。由于我们只针对CAN总线接收数据这条主线进行分析。因些,会忽略一些针对CAN协议的设置及初始化等相关代码。
在初始化CAN设备时,我们需要给CAN设备分配NAPI功能。我们通过netif_napi_add()函数将CAN设备添加到NAPI机制列表中。...
分类:
其他好文 时间:
2014-05-18 06:13:15
阅读次数:
317
中午,不知道动到项目的哪个地方了,之前在联系人列表页面用的好好的jstl标签库突然报错了:的时候报错,说找不到uri。我之前是配置好了的,于是在Eclipse菜单栏找到project-clean,清理当前项目,然后就好了。如果这个方法行不通,而你的项目恰好又是通过Maven来管理的,那么可以在项目上右键-选择run
as-Maven clean。同样也可解决问题。
Ps:刚引入jstl标签库...
分类:
编程语言 时间:
2014-05-18 05:59:51
阅读次数:
231
1、
??
Path Sum
Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.
For example:
Given the below...
分类:
其他好文 时间:
2014-05-18 03:25:06
阅读次数:
301