【题目】
Given a string S and a string T, count the number of distinct subsequences of T in S.
A subsequence of a string is a new string which is formed from the original string by deleting some (can be none) of the characters without disturbing the relati...
分类:
其他好文 时间:
2014-06-29 07:27:17
阅读次数:
210
题目
Given preorder and inorder traversal of a tree, construct the binary tree.
Note:
You may assume that duplicates do not exist in the tree.
方法
根据树的中序遍历和前序遍历,来构造树,使用递归的思想。
Tre...
分类:
其他好文 时间:
2014-06-20 12:14:49
阅读次数:
262
PREPARE statement_name FROM sql_text /*定义*/ EXECUTE statement_name [USING variable [,variable...]] /*执行预处理语句*/ DEALLOCATE PREPARE statement_name /*删除定义*/ 这是我项目当中用到的,用作参考使用:DELIMITER $$
DROP PROC...
分类:
数据库 时间:
2014-06-20 11:22:00
阅读次数:
279
DatabaseHelper.java
package com.example.android_sqlite.database;
import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteDatabase.CursorFa...
分类:
数据库 时间:
2014-06-20 10:44:04
阅读次数:
312
17.4、Making User-Managed Backups of Online Tablespaces and Datafiles
当数据库打开时,可以备份一个在线表空间所有和一个指定的数据文件。备份过程的区别依赖于在线表空间是read、write或者read-only。
注意:不应该备份临时表空间
17.4.1、Making User-Managed Backups of Onlin...
分类:
其他好文 时间:
2014-06-20 10:04:43
阅读次数:
289
.\Obj\HST3GSTM32F205.axf: Error: L6218E: Undefined symbol get_host_by_name (referred from neti_tcpip.o).
.\Obj\HST3GSTM32F205.axf: Error: L6218E: Undefined symbol tcp_abort (referred from neti_tcpip....
分类:
其他好文 时间:
2014-06-07 16:22:39
阅读次数:
260
题目
Given inorder and postorder traversal of a tree, construct the binary tree.
Note:
You may assume that duplicates do not exist in the tree.
方法
根据树的中序遍历和后序遍历,来恢复树,使用递归的思想。
Tr...
分类:
其他好文 时间:
2014-06-07 14:50:37
阅读次数:
231
By starting at the top of the triangle below and moving to adjacent numbers on the row below, the maximum total from top to bottom is 23.
3
7 4
2 4 6
8 5 9 3
That is, 3 + 7 + 4 + 9 = 23.
Find th...
分类:
其他好文 时间:
2014-06-07 13:45:25
阅读次数:
189
并查集,
删除节点操作,可以用新建节点代替
维护每个点到跟节点的距离
Gears
Time Limit: 2 Seconds Memory Limit: 65536 KB
Bob has N (1 ≤ N ≤ 2*105) gears (numbered from 1 to N). Each gear can rotate clockwise or co...
分类:
其他好文 时间:
2014-06-07 11:33:37
阅读次数:
227
如果A,B两个表中没有重复数据且表结构一样可以直接insert into B select *
from A如果结构不一样可以 insert into B(字段列表),select 字段列表 from A如果A,B两表中有重复数据可以 insert
into B(字段列表),select 字段列表 ...
分类:
其他好文 时间:
2014-06-07 08:05:50
阅读次数:
227