#include<cstdio>
#include<iostream>
#include<map>
#include<cstring>
#include<vector>
#include<cmath>
#include<algorithm>
using namespace std;
#define x first
#define y second
#define MAX 110
typedef pair<double,double>pii;
pii point[MAX];
int parent[MAX];
struct edge
{
int a,b;
double w ...
Search found 3 matches
- Fri Nov 29, 2013 3:52 am
- Forum: Volume 100 (10000-10099)
- Topic: 10034 - Freckles
- Replies: 101
- Views: 49017
- Wed Nov 13, 2013 5:27 am
- Forum: Volume 4 (400-499)
- Topic: 459 - Graph Connectivity
- Replies: 133
- Views: 57935
Re: 459 - Graph Connectivity - WA
#include<cstdio>
#include<iostream>
#include<string>
#include<vector>
#include<cstring>
using namespace std;
#define MAX 500
int parent[MAX];
int find_r(int a);
void make_set(int N);
void Union(int a, int b);
int disjoint_count(int n);
void make_set(int N)
{
for(int i=1;i<=N;i++)
parent =i ...
#include<iostream>
#include<string>
#include<vector>
#include<cstring>
using namespace std;
#define MAX 500
int parent[MAX];
int find_r(int a);
void make_set(int N);
void Union(int a, int b);
int disjoint_count(int n);
void make_set(int N)
{
for(int i=1;i<=N;i++)
parent =i ...
- Sat Aug 24, 2013 9:02 am
- Forum: Volume 3 (300-399)
- Topic: 336 - A Node Too Far
- Replies: 121
- Views: 58656
Re: 336 WA
Hello, For the AC output given here ..
1
10 11 //Only one edge
//input
1
10 11
10 0 10 1 10 2 12 1 10 0 10 1 10 2 0 0
0
Case 147: 1 nodes not reachable from node 10 with TTL = 0.
Case 148: 0 nodes not reachable from node 10 with TTL = 1. //here the first one
Case 149: 0 nodes not reachable from ...
1
10 11 //Only one edge
//input
1
10 11
10 0 10 1 10 2 12 1 10 0 10 1 10 2 0 0
0
Case 147: 1 nodes not reachable from node 10 with TTL = 0.
Case 148: 0 nodes not reachable from node 10 with TTL = 1. //here the first one
Case 149: 0 nodes not reachable from ...