题目链接:http://dsalgo.openjudge.cn/graph/10/submit/
AC代码
#include <cstdio>
#include <vector>
#include <stack>
using namespace std;
vector<int> nexts[100001];
stack<int> topo;
int prevs[100001];
int main() {
int N, n, m, a, b;
scanf
题目链接:http://dsalgo.openjudge.cn/graph/10/submit/
#include <cstdio>
#include <vector>
#include <stack>
using namespace std;
vector<int> nexts[100001];
stack<int> topo;
int prevs[100001];
int main() {
int N, n, m, a, b;
scanf