Search found 155 matches

by tan_Yui
Mon Dec 11, 2006 2:30 am
Forum: Volume 1 (100-199)
Topic: 100 - The 3n + 1 problem
Replies: 1394
Views: 183014

mhulboj wrote:Could someone provide a hint why this code yields WA?
If "2 3" was inputted, output should be "2 3 8". :)

By the way, you should remove your JUDGE_ID from your previous post by editing,
because there is danger to which your ID is misused by the third party.

Best regards.
by tan_Yui
Wed Dec 06, 2006 11:49 pm
Forum: Volume 1 (100-199)
Topic: 120 - Stacks of Flapjacks
Replies: 118
Views: 13458

Roby wrote:8 4 6 7 5 2
1 2 3 4 5
5 4 3 2 1
5 1 2 3 4
My output is :
8 4 6 7 5 2
1 4 2 5 3 4 5 0
1 2 3 4 5
0
5 4 3 2 1
1 0
5 1 2 3 4
1 2 0
Please check my previous post again.
And, we don't need to consider about the last 2 cases, as mosaick2 says.

Best regards.
by tan_Yui
Wed Dec 06, 2006 9:09 am
Forum: Volume 1 (100-199)
Topic: 120 - Stacks of Flapjacks
Replies: 118
Views: 13458

I think your approach is correct. But the flips' ID is a bit funny. (.... you may have done it on purpose to explain plainly for us) :) Convert to "ID = (Number of pancakes) + 1 - ID". 8 4 6 7 5 2 -> 1 2 5 7 6 4 8 -> 4 7 5 2 6 4 8 -> 2 4 6 2 5 7 8 -> 5 6 4 2 5 7 8 -> 3 5 2 4 6 7 8 -> 4 4 2 5 6 7 8 -...
by tan_Yui
Sat Nov 25, 2006 11:37 pm
Forum: Volume 1 (100-199)
Topic: 160 - Factors and Factorials
Replies: 205
Views: 24702

if(hasil[i]) { else printf("%3lld", hasil[i]); counter++; } In this part, 'else' is illegal then return compile error. By the way, there are already many many threads about problem 160. http://online-judge.uva.es/board/search.php Did you check all posts from here? There are a lot of test data, so y...
by tan_Yui
Mon Nov 20, 2006 10:32 am
Forum: Volume 100 (10000-10099)
Topic: 10050 - Hartals
Replies: 59
Views: 19023

Re: why runtime error hartals:10050?

newton wrote:may you check it please?
both of c and c++ compiler told me runtime error.
but why?
array[1000] -> array[3651]
day[3651] -> day[100]

After getting correct answer, please delete above your code.

Best regards.
by tan_Yui
Sun Oct 29, 2006 2:37 am
Forum: Volume 1 (100-199)
Topic: 108 - Maximum Sum
Replies: 233
Views: 22775

I think the cause of WA is the little bugs in your code, but I can't analyze because I'm not good at C++.
I'll only give you critical test case. :)

Code: Select all

5
-3 -2 -1  0  1
-2 -1  0  1  2
-1  0  1  2  3
 0  1  2  3 -4
 1  2  3 -4 -5
The answer is 10, but your output is 11.

Best regards.
by tan_Yui
Sat Oct 28, 2006 12:10 pm
Forum: Volume 109 (10900-10999)
Topic: 10905 - Children's Game
Replies: 66
Views: 25734

Re: got WA...

Hi, jan_holmes.
Your code was failed in the following case.

Code: Select all

5
1 120 1201 12012 120120
5
7 768 7687 76876 768768
0
Correct output is :

Code: Select all

1201212012012012011
7768776876876876876
Best regards.
by tan_Yui
Sat Oct 28, 2006 10:48 am
Forum: Volume 1 (100-199)
Topic: 108 - Maximum Sum
Replies: 233
Views: 22775

Try these test cases :)

Code: Select all

4
0  0  0  0
1  1 -4  3
1  2 -5  4
1  3 -6  5

Code: Select all

4
0  1  1  1
0  1  2  3
0 -4 -5 -6
0  3  4  5
Both of thier answers are 12.

Best regards.
by tan_Yui
Tue Oct 10, 2006 7:01 pm
Forum: Volume 109 (10900-10999)
Topic: 10948 - The primary problem
Replies: 27
Views: 18061

Re: 10948 pls help

Hi,
your code didn't return N itself as a part of output, if N cannot be represented as the sum of two prime number.
Please check your output format carefully. :)

Best regards.
by tan_Yui
Sat Oct 07, 2006 11:23 am
Forum: Volume 3 (300-399)
Topic: 301 - Transportation
Replies: 13
Views: 4882

Hi, I'm trying to solve this problem, but got WA. I want to know the information about the problem description. Can anyone help me? 10 4 8 0 1 1 0 2 2 0 3 3 1 2 3 1 3 4 1 4 5 2 4 6 3 4 7 0 0 0 Can the train pass the station visited once? For example, in above test case, if the train can pass the sta...
by tan_Yui
Sun Sep 24, 2006 10:00 am
Forum: Volume 1 (100-199)
Topic: 116 - Unidirectional TSP
Replies: 226
Views: 36117

Re: 116 wa..........asking for help!!

I don't know what is wrong in your code, but please check this input. http://online-judge.uva.es/board/viewtopic.php?t=7804&start=15 4 29 1 -1 0 0 1 -1 -1 -1 1 1 0 1 -1 -1 -1 0 -1 -1 1 -1 1 0 0 -1 0 -1 1 1 0 -1 1 0 -1 -1 0 1 0 -1 -1 -1 -1 1 1 0 -1 -1 0 -1 -1 1 -1 1 0 -1 1 0 1 -1 0 0 1 0 -1 1 0 0 1 1...
by tan_Yui
Thu Sep 21, 2006 8:43 am
Forum: Volume 100 (10000-10099)
Topic: 10036 - Divisibility
Replies: 37
Views: 10884

Re: 10036 RE please help

Hi,
the range of N is 1 <= N <= 10000.
So, you have to assume the special case N = 1. :)

Best regards.
by tan_Yui
Tue Sep 12, 2006 4:52 pm
Forum: Volume 1 (100-199)
Topic: 147 - Dollars
Replies: 233
Views: 21283

Hi, farzane. First of all, read problem again, then you'll found this description. New Zealand currency consists of $100, $50, $20, $10, and $5 notes and $2, $1, 50c, 20c, 10c and 5c coins. But, you wrote only 8 kinds of coins. And, the output may be very large value. For example, 20.00 2886726 30.0...
by tan_Yui
Thu Sep 07, 2006 10:06 pm
Forum: Other words
Topic: Usage of this board
Replies: 0
Views: 1428

Usage of this board

Hi, everyone. I have a question about the usage of this board. When I read/write or edit the post, I am troubled with the character(letter) at the end of line. For example, every line has an additional blank space in the end of line. But, if there are no characters except for '\n' (blank line) or an...
by tan_Yui
Thu Sep 07, 2006 8:11 pm
Forum: Volume 3 (300-399)
Topic: 306 - Cipher
Replies: 74
Views: 18522

I got many WA, but I could solve finally. I missed out this part. Next lines contain integer number k and one message of ascii characters separated by one space . If you faced same problem as me, please try the following case. :) Input: 10 4 5 3 7 2 8 1 6 10 9 14 eccApted!! 12 Accepted! 16 hesAnTwer...

Go to advanced search