Language: C++

class Strongly_Connected_Components {
private:
	int n;
	vvi G;
	vvi rG;
	vi visited;
	stack<int> order;
public:
	vvi ret;
	Strongly_Connected_Components(vvi A) {
		G = A;
		n = G.size();
		rG.resize(n);
		Loop(i, n) {
			Loop(j, G[i].size()) {
				rG[G[i][j]].push_back(i);
			}
		}
		visited.resize(n);
		fill(visited.begin(), visited.end(), 0);
		mainf();
	}
	void dfs(int a) {
		visited[a] = 1;
		Loop(j, G[a].size()) {
			if (visited[G[a][j]]) continue;
			dfs(G[a][j]);
		}
		order.push(a);
	}
	void rdfs(int a) {
		visited[a] = 1;
		Loop(j, rG[a].size()) {
			if (visited[rG[a][j]]) continue;
			rdfs(rG[a][j]);
		}
		ret.back().push_back(a);
	}
	void mainf() {
		Loop(i, n) {
			if (visited[i]) continue;
			dfs(i);
		}
		fill(visited.begin(), visited.end(), 0);
		while (order.size()) {
			int focus = order.top(); order.pop();
			if (visited[focus]) continue;
			ret.push_back({});
			rdfs(focus);
		}
	}
};

Compiler output:
a.cc:4:9: error: 'vvi' does not name a type
    4 |         vvi G;
      |         ^~~
a.cc:5:9: error: 'vvi' does not name a type
    5 |         vvi rG;
      |         ^~~
a.cc:6:9: error: 'vi' does not name a type; did you mean 'void'?
    6 |         vi visited;
      |         ^~
      |         void
a.cc:7:9: error: 'stack' does not name a type
    7 |         stack<int> order;
      |         ^~~~~
a.cc:9:9: error: 'vvi' does not name a type
    9 |         vvi ret;
      |         ^~~
a.cc:10:42: error: expected ')' before 'A'
   10 |         Strongly_Connected_Components(vvi A) {
      |                                      ~   ^~
      |                                          )
a.cc: In member function 'void Strongly_Connected_Components::dfs(int)':
a.cc:24:17: error: 'visited' was not declared in this scope
   24 |                 visited[a] = 1;
      |                 ^~~~~~~
a.cc:25:22: error: 'j' was not declared in this scope
   25 |                 Loop(j, G[a].size()) {
      |                      ^
a.cc:25:25: error: 'G' was not declared in this scope
   25 |                 Loop(j, G[a].size()) {
      |                         ^
a.cc:25:17: error: 'Loop' was not declared in this scope
   25 |                 Loop(j, G[a].size()) {
      |                 ^~~~
a.cc:29:17: error: 'order' was not declared in this scope
   29 |                 order.push(a);
      |                 ^~~~~
a.cc: In member function 'void Strongly_Connected_Components::rdfs(int)':
a.cc:32:17: error: 'visited' was not declared in this scope
   32 |                 visited[a] = 1;
      |                 ^~~~~~~
a.cc:33:22: error: 'j' was not declared in this scope
   33 |                 Loop(j, rG[a].size()) {
      |                      ^
a.cc:33:25: error: 'rG' was not declared in this scope
   33 |                 Loop(j, rG[a].size()) {
      |                         ^~
a.cc:33:17: error: 'Loop' was not declared in this scope
   33 |                 Loop(j, rG[a].size()) {
      |                 ^~~~
a.cc:37:17: error: 'ret' was not declared in this scope
   37 |                 ret.back().push_back(a);
      |                 ^~~
a.cc: In member function 'void Strongly_Connected_Components::mainf()':
a.cc:40:22: error: 'i' was not declared in this scope
   40 |                 Loop(i, n) {
      |                      ^
a.cc:40:17: error: 'Loop' was not declared in this scope
   40 |                 Loop(i, n) {
      |                 ^~~~
a.cc:44:22: error: 'visited' was not declared in this scope
   44 |                 fill(visited.begin(), visited.end(), 0);
      |                      ^~~~~~~
a.cc:44:17: error: 'fill' was not declared in this scope
   44 |                 fill(visited.begin(), visited.end(), 0);
      |                 ^~~~
a.cc:45:24: error: 'order' was not declared in this scope
   45 |                 while (order.size()) {
      |                        ^~~~~
a.cc:48:25: error: 'ret' was not declared in this scope
   48 |                         ret.push_back({});
      |                         ^~~