会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
SunCY
博客园
首页
新随笔
联系
订阅
管理
上一页
1
···
4
5
6
7
8
9
10
11
12
下一页
2020年3月14日
D - Cyclic Components 并查集好题
摘要: 并查集 #include<iostream> #include<string.h> #include<algorithm> #include<cmath> #include<map> #include<string> #include<stdio.h> #include<vector> #inclu
阅读全文
posted @ 2020-03-14 23:12 SunCY
阅读(94)
评论(0)
推荐(0)
2020年3月13日
STL - K - The SetStack Computer UVA - 12096 交集并集
摘要: 注意set的交集和并集的写法 #include<bits/stdc++.h> using namespace std; map< set<int>,int > Map; vector< set<int> > Setcache; stack<int> sta; int ID( set<int> x)
阅读全文
posted @ 2020-03-13 22:24 SunCY
阅读(125)
评论(0)
推荐(0)
输入输出-有一个写了加速会超时的题,得用scanf printf
摘要: 带标记的并查集 ,原来加速后也不见得就很快了 #include<cstdio> #include<iostream> #define endl '\n' #define _for(i,a,b) for(int i=a;i<b;i++) using namespace std; const int N
阅读全文
posted @ 2020-03-13 22:11 SunCY
阅读(282)
评论(0)
推荐(0)
并查集- F - 食物链 POJ - 1182
摘要: https://vjudge.net/contest/360957#problem/F 题解 https://blog.csdn.net/niushuai666/article/details/6981689 #include<iostream> #include<cstdio> #include<
阅读全文
posted @ 2020-03-13 20:56 SunCY
阅读(132)
评论(0)
推荐(0)
STL - E - Sequence POJ - 2442
摘要: https://vjudge.net/contest/360957#problem/E m行n列的一个矩阵 求:每行选一个数,求前n个最小的sum是多少。 思路用优先队列维护前i行的结果,再根据这个遍历求出前i+1行的,以此类推。 #include <iostream> #include <cstd
阅读全文
posted @ 2020-03-13 20:49 SunCY
阅读(100)
评论(0)
推荐(0)
二叉树-根据前序和中序遍历 求出后序遍历
摘要: 不能用线段树开4N空间,因为深度并不确定,最差情况肯定爆内存 解决办法就是反过来建树,根节点->右子树->左子树,建树的过程用stack把结果存下来 #include<bits/stdc++.h> #define endl '\n' #define _for(i,a,b) for(int i=a;i
阅读全文
posted @ 2020-03-13 20:26 SunCY
阅读(447)
评论(0)
推荐(0)
线段树 建树 后序遍历 FBI Tree
摘要: https://vjudge.net/contest/360957#problem/B #include<bits/stdc++.h> #define endl '\n' #define _for(i,a,b) for(int i=a;i<b;i++) using namespace std; co
阅读全文
posted @ 2020-03-13 20:21 SunCY
阅读(138)
评论(0)
推荐(0)
2020年3月12日
用python画函数图像
摘要: 上代码 import numpy as np import matplotlib.pyplot as plt def f(x): return x*x*x+2*x+1.2**x; def plot_f(): x = np.linspace(1,100,1000) y = f(x) # plt.fig
阅读全文
posted @ 2020-03-12 15:11 SunCY
阅读(634)
评论(0)
推荐(0)
2020年3月11日
数据库找不到AdventureWork
摘要: http://121down.com/soft/softview-27651.html#downaddress 下载,里边有教程
阅读全文
posted @ 2020-03-11 15:00 SunCY
阅读(85)
评论(0)
推荐(0)
java CG
摘要: 进制转换 package ch2; import java.util.Scanner; public class CG0311_2 { public static void main(String [] args) { Scanner sc = new Scanner(System.in); lon
阅读全文
posted @ 2020-03-11 14:18 SunCY
阅读(396)
评论(0)
推荐(0)
上一页
1
···
4
5
6
7
8
9
10
11
12
下一页
公告