
Untitled
By: a guest on
Feb 27th, 2012 | syntax:
C++ | size: 0.42 KB | hits: 11 | expires: Never
int n;
map<string,int> users;
map<string,int> ulen;
int graph[300][300];
int idx = 0;
cin >> n;
for(int i = 0; i < n; i++) {
for(int j = 0; j < 3; j++) {
cin >> name;
users[name] = idx;
for(int k = (j - 1); k >= 0; k--) {
graph[j][k] = 1;
graph[k][j] = 1;
}
idx++;
}
}