Oracle创建序列,删除序列,得到序列序列的创建create sequence seq_newsId increment by 1 start with 1 maxvalue 999999999;得到序列的SQL语句select seq_newsid.nextval from sys.dual;删...
分类:
数据库 时间:
2014-07-22 22:44:32
阅读次数:
272
The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1is read off as"one 1"or11.11is read off as"tw...
分类:
其他好文 时间:
2014-07-22 22:43:14
阅读次数:
198
Sorting It All Out
Time Limit: 1000MS
Memory Limit: 10000K
Total Submissions: 26911
Accepted: 9285
Description
An ascending sorted sequence of distinct values is one ...
分类:
其他好文 时间:
2014-07-22 22:38:36
阅读次数:
166
Number Sequence
Time Limit: 10000/5000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 10571 Accepted Submission(s): 4814
Problem Description
Given two ...
分类:
其他好文 时间:
2014-07-22 22:34:32
阅读次数:
194
开始还以为暴力做不出来,需要找规律,找了半天找不出来,原来直接暴力。。
代码如下:
#include
int a[1000050];
int b[100000000]={0};
int main()
{
int i,k;
a[0]=0;
for(i=1;i0...
分类:
其他好文 时间:
2014-07-22 17:46:51
阅读次数:
160
Wavio Sequence
Wavio is a sequence of integers. It has some interesting properties.
· Wavio is of odd length i.e. L = 2*n + 1.
· The first (n+1) integers of Wavio sequence makes a strictly i...
分类:
其他好文 时间:
2014-07-22 14:36:14
阅读次数:
248
UVA 10689 - Yet another Number Sequence
题目链接
题意:斐波那契给前两项,求出第n项,并保留m位
思路:挺裸的矩阵快速幂,就是取模的值是10^m
代码:
#include
#include
const int mod[5] = {0, 10, 100, 1000, 10000};
int t, a, b, n, m;
s...
分类:
其他好文 时间:
2014-07-22 00:31:37
阅读次数:
279
DescriptionThe Farey Sequence Fn for any integer n with n >= 2 is the set of irreducible rational numbers a/b with 0 < a < b <= n and gcd(a,b) = 1 arr...
分类:
其他好文 时间:
2014-07-22 00:20:35
阅读次数:
283
直接套KMP模板
#include
#include
#include
using namespace std;
int s[1000005],w[10005],next[10005];
int b,c;
void show()
{
int i,j;
i=0;
next[0]=-1;
j=-1;
while(i<c)
{
if(j=...
分类:
其他好文 时间:
2014-07-21 23:29:03
阅读次数:
334
Distinct Subsequences
A subsequence of a given sequence is just the given sequence with some elements (possibly none) left out. Formally, given a sequence X = x1x2…xm,
another sequence Z = z1...
分类:
其他好文 时间:
2014-07-21 15:44:16
阅读次数:
244