会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
痴月
博客园
首页
新随笔
联系
订阅
管理
上一页
1
···
13
14
15
16
17
18
19
20
21
···
27
下一页
2018年9月10日
Fantasy of a Summation (LightOJ - 1213)(快速幂+简单思维)
摘要: 题解:根据题目给的程序,就是计算给的这个序列,进行k次到n的循环,每个数需要加的次数是k*n^(k-1),所以快速幂取模,算计一下就可以了。#include using namespace std;typedef long long ll;const int INF...
阅读全文
posted @ 2018-09-10 21:15 Mercury_Lc
阅读(111)
评论(0)
推荐(0)
2018年9月5日
顺序表应用8:最大子段和之动态规划法(SDUT 3665)
摘要: Problem Description 给定n(1using namespace std;const int maxn = 100001;struct node{ int *elem; int len;};void Creatlist(struct nod...
阅读全文
posted @ 2018-09-05 15:24 Mercury_Lc
阅读(128)
评论(0)
推荐(0)
顺序表应用8:最大子段和之动态规划法(SDUT 3665)
摘要: Problem Description 给定n(1using namespace std;const int maxn = 100001;struct node{ int *elem; int len;};void Creatlist(struct nod...
阅读全文
posted @ 2018-09-05 15:24 Mercury_Lc
阅读(164)
评论(0)
推荐(0)
顺序表应用6:有序顺序表查询(SDUT 3330)
摘要: Problem Description顺序表内按照由小到大的次序存放着n个互不相同的整数,任意输入一个整数,判断该整数在顺序表中是否存在。如果在顺序表中存在该整数,输出其在表中的序号;否则输出“No Found!"。Input 第一行输入整数n (1 using na...
阅读全文
posted @ 2018-09-05 14:17 Mercury_Lc
阅读(191)
评论(0)
推荐(0)
顺序表应用6:有序顺序表查询(SDUT 3330)
摘要: Problem Description顺序表内按照由小到大的次序存放着n个互不相同的整数,任意输入一个整数,判断该整数在顺序表中是否存在。如果在顺序表中存在该整数,输出其在表中的序号;否则输出“No Found!"。Input 第一行输入整数n (1 using na...
阅读全文
posted @ 2018-09-05 14:17 Mercury_Lc
阅读(144)
评论(0)
推荐(0)
2018年9月4日
顺序表应用5:有序顺序表归并(SDUT 3329)
摘要: Problem Description已知顺序表A与B是两个有序的顺序表,其中存放的数据元素皆为普通整型,将A与B表归并为C表,要求C表包含了A、B表里所有元素,并且C表仍然保持有序。Input 输入分为三行:第一行输入m、n(1#include #include c...
阅读全文
posted @ 2018-09-04 17:10 Mercury_Lc
阅读(184)
评论(0)
推荐(0)
顺序表应用5:有序顺序表归并(SDUT 3329)
摘要: Problem Description已知顺序表A与B是两个有序的顺序表,其中存放的数据元素皆为普通整型,将A与B表归并为C表,要求C表包含了A、B表里所有元素,并且C表仍然保持有序。Input 输入分为三行:第一行输入m、n(1#include #include c...
阅读全文
posted @ 2018-09-04 17:10 Mercury_Lc
阅读(238)
评论(0)
推荐(0)
顺序表应用4-2:元素位置互换之逆置算法(数据改进)(SDUT 3663)
摘要: Problem Description一个长度为len(1#include #include const int maxn = 1000000;struct node{ int *elem; int len;};void Creatlist(int len...
阅读全文
posted @ 2018-09-04 10:55 Mercury_Lc
阅读(141)
评论(0)
推荐(0)
顺序表应用4-2:元素位置互换之逆置算法(数据改进)(SDUT 3663)
摘要: Problem Description一个长度为len(1#include #include const int maxn = 1000000;struct node{ int *elem; int len;};void Creatlist(int len...
阅读全文
posted @ 2018-09-04 10:55 Mercury_Lc
阅读(470)
评论(0)
推荐(0)
顺序表应用3:元素位置互换之移位算法(SDUT 3326)
摘要: 题解:用一个for,循环m次,每次都把最前面的放到最后面,就可以了。#include #include #include const int maxn = 1000000;struct node{ int *elem; int len;};void C...
阅读全文
posted @ 2018-09-04 10:00 Mercury_Lc
阅读(148)
评论(0)
推荐(0)
上一页
1
···
13
14
15
16
17
18
19
20
21
···
27
下一页
公告