摘要: A. 食物链 题目描述 如图所示为某生态系统的食物网示意图,据图回答此题。 现在给你n 个物种和 m条能量流动关系,求其中的食物链条数。 物种的名称为从1 到 n的编号。 m条能量流动关系形如 其中 ai,bi表示能量从物种ai 流向物种bi 。注意单独的一种孤立生物不算一条食物链。 输入格式 第一 阅读全文
posted @ 2020-07-05 21:29 LightyaChoo 阅读(172) 评论(2) 推荐(0) 编辑
摘要: #include<bits/stdc++.h> using namespace std; const int n=1010; int h[n]; int N; int f[n][n][2]; int main(){ scanf("%d",&N); for(int i=1;i<=N;i++){ sca 阅读全文
posted @ 2020-07-05 21:23 LightyaChoo 阅读(173) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h> using namespace std; const int n=55; char s[n]; int f[n][n]; //const int INF=1e8; int main(){ scanf("%s",s+1); int len = strle 阅读全文
posted @ 2020-07-05 21:22 LightyaChoo 阅读(105) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h> using namespace std; const int n=2010; char a[n],b[n]; int dp[n][n]; int main(){ scanf("%s%s",a+1,b+1); int l1 = strlen(a+1); 阅读全文
posted @ 2020-07-05 21:21 LightyaChoo 阅读(107) 评论(0) 推荐(0) 编辑
摘要: 1 #include<iostream> 2 #include<stack> 3 #include<cstdio> 4 using namespace std; 5 const int N = 12000; 6 7 struct edge{ 8 int to; 9 int next; 10 }e[N 阅读全文
posted @ 2020-07-05 21:20 LightyaChoo 阅读(143) 评论(0) 推荐(0) 编辑
摘要: #include<bits/stdc++.h> using namespace std; typedef long long ll; const ll N=1000010; ll n,m; ll a[N]; struct Node{ ll it; ll l; ll r; ll data; }tree 阅读全文
posted @ 2020-07-05 21:19 LightyaChoo 阅读(85) 评论(0) 推荐(0) 编辑
摘要: 1 #include<bits/stdc++.h> 2 using namespace std; 3 typedef long long ll; 4 const ll N=1000010; 5 ll n,m; 6 ll a[N]; 7 8 struct Node{ 9 ll it; 10 ll l; 阅读全文
posted @ 2020-07-05 21:18 LightyaChoo 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 1 #include<bits/stdc++.h> 2 using namespace std; 3 typedef long long ll; 4 const ll N=100100; 5 ll minn[N<<2]; 6 ll a[N]; 7 ll n,m; 8 ll cnt; 9 void b 阅读全文
posted @ 2020-07-05 21:17 LightyaChoo 阅读(147) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2020-07-05 21:08 LightyaChoo 阅读(118) 评论(7) 推荐(1) 编辑