I tried to solve the problem in the following way:
create the suffix array of the string -> sort in lexicographic order ->
check the prefixes of the prefixes of succesive terms, and print the best.
My output is correct the the huge test data provided in a previous post,
but still I am getting WA ...
Search found 16 matches
- Fri Jul 30, 2010 8:21 am
- Forum: Volume 115 (11500-11599)
- Topic: 11512 - GATTACA
- Replies: 23
- Views: 12968
- Fri Dec 04, 2009 10:48 am
- Forum: Volume 102 (10200-10299)
- Topic: 10249 - The Grand Dinner
- Replies: 19
- Views: 16777
Re: 10249 - The Grand Dinner
I am trying to solve it with the greedy approach, that it was described before,
but till now I have a lot of WA.
I used both ways for the tables, unsorted and sorted according to the capacity.
Is there any special case I have to consider?
The boundary conditions are correct?
Should the ...
but till now I have a lot of WA.
I used both ways for the tables, unsorted and sorted according to the capacity.
Is there any special case I have to consider?
The boundary conditions are correct?
Should the ...
- Sat May 19, 2007 8:39 pm
- Forum: Volume 107 (10700-10799)
- Topic: 10714 - Ants
- Replies: 20
- Views: 16648
Can someone explain why the output for
is
and not
Thanks in advance for any reply.
Code: Select all
1
10 3
3 7 9
Code: Select all
3 9
Code: Select all
3 8
Thanks in advance for any reply.
- Tue May 01, 2007 3:00 pm
- Forum: Volume 109 (10900-10999)
- Topic: 10914 - Abundance and Perfect Numbers
- Replies: 20
- Views: 10382
- Wed Apr 18, 2007 4:52 pm
- Forum: Volume 110 (11000-11099)
- Topic: 11026 - A Grouping Problem
- Replies: 28
- Views: 23839
- Fri Aug 11, 2006 1:41 pm
- Forum: Volume 6 (600-699)
- Topic: 699 - The Falling Leaves
- Replies: 7
- Views: 7514
Misundarstanding in 699 , "The Falling Leaves".
I can not figure out with my poor english what means in the problem explanation the phrase:
"...This display must start in column 1, and will not exceed the width of an 80-character line...."
that we will take as a fact that the output lines will be less than 80 characters, or that we should take ...
"...This display must start in column 1, and will not exceed the width of an 80-character line...."
that we will take as a fact that the output lines will be less than 80 characters, or that we should take ...
- Fri Jul 14, 2006 6:32 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10099 - The Tourist Guide
- Replies: 91
- Views: 43009
Hi.
it seems that I have an unsolvable problem with 10099.
The algorithm seems simple but I'm receiving WA continously.
Can someone take a look at my code?
Thanks in advance for any suggestion,
grazyna
it seems that I have an unsolvable problem with 10099.
The algorithm seems simple but I'm receiving WA continously.
Can someone take a look at my code?
Code: Select all
thanks for anybody who tried.
I had mistake in reading the data
grazyna
- Thu Jul 21, 2005 1:21 pm
- Forum: Volume 8 (800-899)
- Topic: 847 - A Multiplication Game
- Replies: 41
- Views: 28173
- Thu Jun 02, 2005 12:56 am
- Forum: Volume 8 (800-899)
- Topic: 847 - A Multiplication Game
- Replies: 41
- Views: 28173
judge wrong ...?
I just got accepted assuming according to the advices of the forum that from 19 -> 162 Stan is winning. But still I think that judge is wrong on this problem...
- Wed Jun 01, 2005 11:53 am
- Forum: Volume 8 (800-899)
- Topic: 847 - A Multiplication Game
- Replies: 41
- Views: 28173
Question on 847 (multiplication game)
I read all the posts and I can not find where is the fault in my logic:
I read that is considered corect that from 18 -> 162 Stan wins.
Let them choose 50: Stan of course starts with 2. (Otherwise he looses since Ollie will return 81.) Ollie responds with 4. Stan now will return 8 or 36. In any ...
I read that is considered corect that from 18 -> 162 Stan wins.
Let them choose 50: Stan of course starts with 2. (Otherwise he looses since Ollie will return 81.) Ollie responds with 4. Stan now will return 8 or 36. In any ...
- Sun May 29, 2005 11:46 pm
- Forum: Volume 1 (100-199)
- Topic: 107 - The Cat in the Hat
- Replies: 278
- Views: 54841
- Sun May 29, 2005 5:39 pm
- Forum: Volume 1 (100-199)
- Topic: 107 - The Cat in the Hat
- Replies: 278
- Views: 54841
some question on problem 107
I am trying to solve 107 using long long and I am getting WA.
should I use double , since the problem clarifies that it has to do with integers?
more over I saw in the forum the sample input 11 10 ,
with the output 1 21.
Is it valid input? As far as for the input pair a b there should be ...
should I use double , since the problem clarifies that it has to do with integers?
more over I saw in the forum the sample input 11 10 ,
with the output 1 21.
Is it valid input? As far as for the input pair a b there should be ...
- Sat May 28, 2005 4:06 pm
- Forum: Volume 100 (10000-10099)
- Topic: 10093 - An Easy Problem!
- Replies: 52
- Views: 22905
10093 SIGFPE Problem . Please help!
I receive runtime error with the message :
Your program has died with signal 8 (SIGFPE). Meaning:
Floating point exception
Before crash, it ran during 0.000 seconds.
for the following code:
Thx everybody who tried. I found my stupid mistake
I don't see any illegal division. Thanks in advance ...
Your program has died with signal 8 (SIGFPE). Meaning:
Floating point exception
Before crash, it ran during 0.000 seconds.
for the following code:
Thx everybody who tried. I found my stupid mistake
I don't see any illegal division. Thanks in advance ...
- Thu Apr 21, 2005 9:32 pm
- Forum: Volume 101 (10100-10199)
- Topic: 10137 - The Trip
- Replies: 159
- Views: 70192
10137
I read all the posts about the problem. I considered the extra pennies , extreme cases etc. I am affraid that I miss something essential about c++ programming and portability. Thanks in advance for any help.
/* @JUDGE_ID: xx 10137 C++ "The Trip" */
#include <iostream>
#include <iomanip>
using ...
/* @JUDGE_ID: xx 10137 C++ "The Trip" */
#include <iostream>
#include <iomanip>
using ...
- Wed Apr 20, 2005 8:34 pm
- Forum: Volume 1 (100-199)
- Topic: 100 - The 3n + 1 problem
- Replies: 1394
- Views: 317799