Hi...
I can tell you that moving the cube on the board may be simulated. For the algo, I think a BFS is the solution
Search found 19 matches
- Sat Nov 13, 2004 4:03 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10021 - Cube in the labirint
- Replies: 17
- Views: 5895
- Fri Oct 08, 2004 12:39 am
- Forum: Volume 107 (10700-10799)
- Topic: 10720 - Graph Construction
- Replies: 49
- Views: 38231
- Thu Oct 07, 2004 3:24 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10021 - Cube in the labirint
- Replies: 17
- Views: 5895
- Thu Oct 07, 2004 9:02 am
- Forum: Volume 100 (10000-10099)
- Topic: 10021 - Cube in the labirint
- Replies: 17
- Views: 5895
- Wed Oct 06, 2004 11:20 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10021 - Cube in the labirint
- Replies: 17
- Views: 5895
10021 - How to solve?
How can I solve this problem?
I've tried DFS first, then BFS, but WA. It seems a cell can be visited more than once. So it would go for TLE, in't it?
I've tried DFS first, then BFS, but WA. It seems a cell can be visited more than once. So it would go for TLE, in't it?
- Thu Sep 30, 2004 11:23 am
- Forum: Volume 100 (10000-10099)
- Topic: 10010 - Where's Waldorf?
- Replies: 42
- Views: 26070
- Thu Sep 30, 2004 10:32 am
- Forum: Volume 100 (10000-10099)
- Topic: 10010 - Where's Waldorf?
- Replies: 42
- Views: 26070
- Thu Sep 30, 2004 10:23 am
- Forum: Volume 100 (10000-10099)
- Topic: 10013 - Super long sums
- Replies: 212
- Views: 67855
- Thu Sep 30, 2004 10:10 am
- Forum: Volume 100 (10000-10099)
- Topic: 10014 - Simple calculations
- Replies: 34
- Views: 13012
- Mon Sep 27, 2004 12:48 am
- Forum: Volume 101 (10100-10199)
- Topic: 10101 - Bangla Numbers
- Replies: 122
- Views: 45519
- Sun Sep 26, 2004 10:08 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10014 - Simple calculations
- Replies: 34
- Views: 13012
- Sun Sep 26, 2004 2:00 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10013 - Super long sums
- Replies: 212
- Views: 67855
- Sun Sep 26, 2004 1:07 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10010 - Where's Waldorf?
- Replies: 42
- Views: 26070
10010 Where the hell is Waldorf? I can't find it!!!
Hye... I am very disappointed. I submitted this problem 20 times and I've got WA for all. Is there some treaky inputs?
Please, people, help me with this easy problem.
Look a little at my code:
#include <stdio.h>
#include <ctype.h>
int m, n; /* num of line & columns */
char grid[60][60];
char viz ...
Please, people, help me with this easy problem.
Look a little at my code:
#include <stdio.h>
#include <ctype.h>
int m, n; /* num of line & columns */
char grid[60][60];
char viz ...
- Sun Sep 26, 2004 1:17 am
- Forum: Volume 102 (10200-10299)
- Topic: 10299 - Relatives
- Replies: 57
- Views: 20748
Solved...
Lastly I've solved this problem. I've got TLE because of square() function which was evaluated every step in the for() loop. Also the above code would give WA even if we improve it.
Problem solution is easy as PI, because it's pure mathematic:
For a number n = p1^a1 * p2^a2 * . . . * pn^an, where ...
Problem solution is easy as PI, because it's pure mathematic:
For a number n = p1^a1 * p2^a2 * . . . * pn^an, where ...
- Sat Sep 25, 2004 7:16 pm
- Forum: Volume 102 (10200-10299)
- Topic: 10299 - Relatives
- Replies: 57
- Views: 20748
10299 - TLE on good algoritm please help
Hy!
I used the clasical algorithm to solve this problem, that means Euler phi function and I still get TLE. I don't know why..
please help me understand why...
Here goes my code:
#include <stdio.h>
#include <math.h>
int main(void)
{
int n, i, phi;
while(scanf("%d", &n) == 1)
{
if(n == 0 ...
I used the clasical algorithm to solve this problem, that means Euler phi function and I still get TLE. I don't know why..
please help me understand why...
Here goes my code:
#include <stdio.h>
#include <math.h>
int main(void)
{
int n, i, phi;
while(scanf("%d", &n) == 1)
{
if(n == 0 ...