205864713
蓝月升空! City三冠王!
-
——
:
Revolving moon and spinning sun, forged a crescent blade.
From light and dark within the heart, the shining sword was made.
The curving arc of Revolute, shimmerd in his hand.:
Flower gleam and glow, let your power shine.
Make the clock reverse, bring back what once was mine.
Heal what has been hurt, change the fate's design.
Save what has been lost, bring what once was mine.
What once was mine.:
Wither and decay, end this destiny.
Break these earthly chains, and set the spirit free.
The spirit free.:
Crescent high above, evolving as you go!
Raise what lies beneath, and let the darkness grow.
Bend it to my will, consume the sunlight's glow.
Rise into the sky, and let the darkness show.:
Power of the sun, gift me with your light.
Shine into the dark, restore our fading sight.
Rise into the dawn, blazing star so bright.
Burn away the strife, let my hope ignite.
Let hope ignite!6.1.2020:AC 300,提交 1000 祭
7.15.2020 YellowBean 官宣 (成为了MOer,但以后还会常来洛谷!)
10.22.2021 省一祭(MO)
11.18.2021 更名祭 OI生命的倒数第三天
东风夜放搜索树,更吹落,WA如雨。 跑TarjanAC满路,评测机动,碧绿光转,一夜AK舞。
#include<bits/stdc++.h>
using namespace std;
int read()
{
char ch=getchar();
int x=0;
while(ch<'0'||ch>'9')ch=getchar();
while(ch>='0'&&ch<='9')x=x*10+ch-'0',ch=getchar();
return x;
}
int n,m;
int v[200005],next[200005],first[20005],tot=1;
int dfn[20005],low[20005],cnt;
bool cut[20005];
int root,ans;
void add(int x,int y){
v[++tot]=y;
next[tot]=first[x];
first[x]=tot;
}
void tarjan(int x){
dfn[x]=low[x]= ++cnt;
int sum=0;
for(int i=first[x];i;i=next[i]){
int y=v[i];
if(!dfn[y]){
tarjan(y);
low[x]=min(low[x],low[y]);
if(low[y]>=dfn[x]){
sum++;
if(x!=root || sum>1)cut[x]=true,ans++;
}
}
else low[x]=min(low[x],dfn[y]);
}
}
int main()
{
memset(cut,false,sizeof(cut));
cin>>n>>m;
for(int i=1;i<=m;i++){
int a=read(),b=read();
add(a,b);add(b,a);
}
for(int i=1;i<=n;i++)
if(!dfn[i])root=i,tarjan(i);
ans=0;
for(int i=1;i<=n;i++)
if(cut[i])ans++;
cout<<ans<<endl;
for(int i=1;i<=n;i++)
if(cut[i])cout<<i<<' ';
cout<<endl;
return 0;
}