Lang:G++
Edit12345678910111213141516171819202122232425262728293031#include <cstdio>const int sizeofpoint=131072;const int sizeofedge=1048576;const int p=142857;inline int getint();inline void putint(int);struct edge{int point;edge * next;};edge memory[sizeofedge], * port=memory;inline edge * newedge(int, edge * );int n, m, k;int f[sizeofpoint];int q[sizeofpoint];int d[sizeofpoint];edge * e[sizeofpoint];int main(){int l=0, r=0;n=getint(), m=getint(), k=getint();for (int i=1;i<=k;i++)f[getint()]++;for (int i=1;i<=m;i++)