Search found 80 matches
- Mon Dec 17, 2007 6:30 am
- Forum: Volume 113 (11300-11399)
- Topic: 11308 - Bankrupt Baker
- Replies: 17
- Views: 9905
WA
Can anyone tell me what's wrong with my code? It gets WA. I handled the potential integer overflow problem with unsigned long long. I concatenated the [cost,recipe] to represent the cost of each recipe. Then I sorted it using qsort. I believe this handles the lexicographical order. Any ideas? Here's...
- Fri Dec 14, 2007 10:07 pm
- Forum: Volume 112 (11200-11299)
- Topic: 11234 - Expressions
- Replies: 15
- Views: 9092
Time Limited Exceeded (TLE)
Does anyone know more ways to optimize this code? I already optimized my queue usage. I'm suspecting I can do my string concatenations faster, but I don't know how to do it. Any ideas how I can get this faster? Here's the code: #include <iostream> #include <string> //11234.cpp using namespace std; i...
- Tue Dec 04, 2007 9:02 am
- Forum: Volume 4 (400-499)
- Topic: 498 - Polly the Polynomial
- Replies: 73
- Views: 20589
- Mon Dec 03, 2007 3:08 am
- Forum: Volume 112 (11200-11299)
- Topic: 11225 - Tarot scores.
- Replies: 9
- Views: 5639
- Sun Dec 02, 2007 9:42 am
- Forum: Volume 112 (11200-11299)
- Topic: 11225 - Tarot scores.
- Replies: 9
- Views: 5639
Silly mistake
Likewise, I bet I have a silly mistake in here somewhere. I've been pulling my hair out trying to find out what it is. Anyone got any ideas?
note:
Since the score is always an integer, I avoided the use of doubles/floats
note:
Since the score is always an integer, I avoided the use of doubles/floats
Code: Select all
code deleted
- Tue Oct 23, 2007 5:56 am
- Forum: Volume 1 (100-199)
- Topic: 119 - Greedy Gift Givers
- Replies: 145
- Views: 42418
- Tue Oct 23, 2007 5:41 am
- Forum: FAQ
- Topic: e-mail problem
- Replies: 0
- Views: 4909
e-mail problem
In the old system, they used to e-mail the error message on compile errors. Now with this new system, they don't do that and there's no way to find out what's wrong with your code if you have a compile error on the judges' system but not on your own system.
- Tue Oct 23, 2007 5:31 am
- Forum: Volume 1 (100-199)
- Topic: 119 - Greedy Gift Givers
- Replies: 145
- Views: 42418
Compile Error
Does anyone know why this gives a compile error? I compile by: g++ filename.cpp it works fine on my own pc, but it has a newer compiler. Does anyone know how to compile down to older versions? Thanks. #include <iostream> #include <string> using namespace std; string line; char num[100][100]; int ans...
- Thu Oct 18, 2007 4:58 pm
- Forum: Volume 4 (400-499)
- Topic: 490 - Rotating Sentences
- Replies: 212
- Views: 43088
- Sat Oct 13, 2007 10:56 am
- Forum: Volume 4 (400-499)
- Topic: 490 - Rotating Sentences
- Replies: 212
- Views: 43088
can someone double check this?
It handles the above input cases exactly and it still gives me presentation error. My current program outputs a newline at the end of output. Weird thing is, if I remove that last newline at the end of the output, it'll say wrong answer. #include <iostream> using namespace std; string str [101]; voi...
- Wed Nov 01, 2006 10:05 am
- Forum: Volume 6 (600-699)
- Topic: 616 - Coconuts, Revisited
- Replies: 37
- Views: 16277
- Wed Nov 01, 2006 9:55 am
- Forum: Volume 6 (600-699)
- Topic: 616 - Coconuts, Revisited
- Replies: 37
- Views: 16277
- Wed Nov 01, 2006 9:45 am
- Forum: Volume 6 (600-699)
- Topic: 616 - Coconuts, Revisited
- Replies: 37
- Views: 16277
- Mon Oct 23, 2006 8:15 pm
- Forum: Volume 4 (400-499)
- Topic: 402 - M*A*S*H
- Replies: 56
- Views: 19216
- Mon Oct 23, 2006 6:00 am
- Forum: Volume 4 (400-499)
- Topic: 402 - M*A*S*H
- Replies: 56
- Views: 19216