## Search found 13 matches

Mon Apr 18, 2011 2:56 am
Forum: Volume 119 (11900-11999)
Topic: 11981 - Corrupted Friendship
Replies: 1
Views: 1571

i haven't solve it yet but i think 100000*100000 is too large :( for(int i=2;i<=nod;i++) { dfs(i); //color[1]=false; for(int j=2;j<=nod;j++) { ... } } And there is a recommended in this problem. Input is huge. So, faster I/O methods (e.g. scanf, printf, BufferedReader, BufferedWriter) are recommende...
Mon Apr 18, 2011 2:51 am
Forum: Volume 118 (11800-11899)
Topic: 11898 - Killer Problem
Replies: 6
Views: 3275

### Re: 11898 - Killer Problem

i use insertion sort + binary search in STL vector. My runtime is 0.568s
p.s: how to use RMQ to solve this problem
Mon Apr 11, 2011 7:18 pm
Forum: Volume 119 (11900-11999)
Topic: 11965 - Extra Spaces
Replies: 31
Views: 7452

### Re: 11965 - Extra Spaces

first, you must

Code: Select all

``scanf("%d",&k);getchar();``
indeed

Code: Select all

``scanf("%d\n",&k);``
second, the last character can be space. It's possible
Mon Apr 11, 2011 12:05 pm
Forum: Volume 119 (11900-11999)
Topic: 11961 - DNA
Replies: 0
Views: 1552

### 11961 - DNA

I don't know why i get WA in this problem , please help me :( //Author: Doan Minh Quy //Problem: 11961 - DNA //Link:http://uva.onlinejudge.org/external/119/11961.html //Algorithm: Generation //@BEGIN SOURCE CODE #include <cstdio> #include <string> #include <vector> #include <iostream> #include <algo...
Sat Jul 17, 2010 5:51 am
Forum: Volume 113 (11300-11399)
Topic: 11377 - Airport Setup
Replies: 24
Views: 11648

### Re: 11377 - Airport Setup

please give me some test case!!! :( i don't understand why i get WA!! here is my code, is it wrong? :( :( :( #include <iostream> #include <vector> #include <queue> #define lim 2010 #define maxL 999999 using namespace std; int N , M , K , sum[lim] , x , y; vector <int> abj[lim]; queue <int> trait; bo...
Mon Jun 28, 2010 3:58 am
Forum: Volume 117 (11700-11799)
Topic: 11797 - Drutojan Express
Replies: 14
Views: 4570

### Re: 11797-WA!

Dear sachin_midha...
i have not known why you got RE but firstly , your code was wrong!!! . Try my case above.....
Mon Jun 28, 2010 3:33 am
Forum: Volume 117 (11700-11799)
Topic: 11795 - Mega Man's Mission
Replies: 6
Views: 3146

### Re: 11795 - Mega Man's Mission

thanks everyone! i will try DP
Sun Jun 27, 2010 5:45 am
Forum: Volume 117 (11700-11799)
Topic: 11797 - Drutojan Express
Replies: 14
Views: 4570

### Re: 11797-WA!

try this

Code: Select all

``````1
10 11 Ja
5 Tan Sid Sam Sha Tan
1 Ja
1 Ja
1 Ja
1 Ja
``````
output should be:

Code: Select all

``````Case 1:
Ja 10
Sam 0
Sha 0
Sid 0
Tan 0
``````
good luck!
Sun Jun 27, 2010 5:10 am
Forum: Volume 117 (11700-11799)
Topic: 11795 - Mega Man's Mission
Replies: 6
Views: 3146

### 11795 - Mega Man's Mission

is it backtracking problem? ....i got TLE when i used backtracking . Please tell me some hint!
Thu Jun 17, 2010 3:35 am
Forum: Volume 117 (11700-11799)
Replies: 32
Views: 5912

### Re: 11723 - Numbering Roads

try this:

Code: Select all

``5 8``
i think output should be

Code: Select all

``Case 1: 0``
Wed Jun 16, 2010 11:27 am
Forum: Volume 117 (11700-11799)
Replies: 32
Views: 5912

### Re: 11723 - Numbering Roads

lnr wrote:Can someone give some hint for this problem?
Can't understand how the result is 1 for input 8 5
you can named 8 streets: 1 2 3 4 5 1A 2A 3A !
So, you only need one suffix!
Fri Jun 11, 2010 3:34 am
Forum: Volume 1 (100-199)
Topic: 147 - Dollars
Replies: 233
Views: 20080

### Re: 147 ,WA

Code: Select all

``````removed after AC
``````
Wed Jun 02, 2010 2:47 pm
Forum: Volume 116 (11600-11699)
Topic: 11699 - Rooks
Replies: 2
Views: 3195

### Re: 11699- getting WA

try this... Input #.............# .#...........#. ..#.........#.# ...#.......#.#. ....#.....#.#.. .....#...#.#... ......#.#.#.... ##########..... ......#.#...... .....#...#..... ....#.....#.... ...#.......#... ..#.........#.. .#...........#. #.............# END right output: 8 p.s : i'm getting WA t...