## Search found 10 matches

- Thu Feb 19, 2015 2:24 pm
- Forum: Other words
- Topic: External Problem Choosing the Pairs
- Replies:
**8** - Views:
**1844**

### Re: External Problem Choosing the Pairs

Yeah i already used this techinique sometimes, but in this problems it can help really a lot...In this test case that you gave me i realized that my idea of matching the 2 degree cycles, which are not matched in the while, is wrong,but i think there's only one way to match them isn't it? i implement...

- Sat Feb 14, 2015 3:04 pm
- Forum: Other words
- Topic: External Problem Choosing the Pairs
- Replies:
**8** - Views:
**1844**

### Re: External Problem Choosing the Pairs

The updated code is this: #include <stdio.h> #include <string.h> #include <stdlib.h> #define MAX 50000 #define MAXVERTEX 10005 #define INFINITY 100000000 typedef struct edge { int u,v; } EDGE; EDGE g[MAX]; //ordering edges of list of edges int compare(const void* a,const void* b) { EDGE x=*(edge*)a;...

- Fri Feb 13, 2015 10:24 pm
- Forum: Other words
- Topic: External Problem Choosing the Pairs
- Replies:
**8** - Views:
**1844**

### Re: External Problem Choosing the Pairs

Thanks, i changed that, but now i'm getting wrong answer without percentage, is this solution in the right way? Is there any tricky test case?

- Thu Feb 12, 2015 2:20 pm
- Forum: Other words
- Topic: External Problem Choosing the Pairs
- Replies:
**8** - Views:
**1844**

### Re: External Problem Choosing the Pairs

I'm getting WA 60%, the code is this: #include <stdio.h> #include <string.h> #include <stdlib.h> #define MAX 50000 #define MAXVERTEX 10005 #define INFINITY 100000000 typedef struct edge { int u,v; } EDGE; EDGE g[MAX]; //ordering edges of list of edges int compare(const void* a,const void* b) { EDGE ...

- Fri Feb 06, 2015 10:03 pm
- Forum: Other words
- Topic: External Problem Choosing the Pairs
- Replies:
**8** - Views:
**1844**

### External Problem Choosing the Pairs

Hi everyone, i'm trying to solve this problem of contest Dalalio: https://www.urionlinejudge.com.br/judge/pt/problems/view/1562 My approach was taking the students as vertexes of an undirected graph G and the edges (a,b) would be if a likes b or b likes a. I used a queue and added initially all vert...

- Thu Feb 05, 2015 3:33 pm
- Forum: Volume 127 (12700-12799)
- Topic: 12795 - Ecology
- Replies:
**4** - Views:
**1142**

### Re: 12795 - Ecology

Thank you very much! With your results i could find my mistakes and solve it. Thanks!

- Wed Feb 04, 2015 4:39 pm
- Forum: Volume 127 (12700-12799)
- Topic: 12795 - Ecology
- Replies:
**4** - Views:
**1142**

### Re: 12795 - Ecology

Please help me with this problem. Are you sure there is only about 36000 shapes for M=10? I wanna test my algorithm, it gives 4900 shapes for M=2, 14404 shapes for M=3...is that right?

- Fri Aug 15, 2014 4:33 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10289 - A Square and Equilateral Triangles
- Replies:
**27** - Views:
**8215**

### Re: 10289 - A Square & Equilateral Triangles

Thank you brianfry. I will try this problem again using numerical ideas, this drawing helped me to understand the figure, the upper triangle is not aligned to the bottom, and this turned the problem to be very hard hehehehe.

- Fri Aug 01, 2014 10:53 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10289 - A Square and Equilateral Triangles
- Replies:
**27** - Views:
**8215**

### Re: 10289 - A Square & Equilateral Triangles

but is it necessary to use some numerical method to get this 0.555? All the geometry i did arrive in 0.554, is the picture for case 5 wrong? Are the heights of the uppermost and bottommost triangle same axis?

- Fri Aug 01, 2014 2:45 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10289 - A Square and Equilateral Triangles
- Replies:
**27** - Views:
**8215**

### Re: 10289 - A Square & Equilateral Triangles

Hi guys... i have to solve this problem for our training to a contest in Brazil... i got that formula for t5 ( sqrt(3) + 2 / sqrt(3) + 5) but after i saw previous messages , people said it's wrong. Can somebody explain me why please? I couldn't understand that ideas before about the 5 case not optim...