Page 3 of 3

Posted: Tue Jan 16, 2007 10:15 pm
by yoshiro aoki
hi, Im yoshiro.

sorry, my problem was I sent an old version of my program to the judge by accident.

The program that passed millions of test cases of course got AC. I enjoyed writing that test case generator : )!!

I posted several critical test cases for this program challenge here, but I don't see them here any more.

I will look again. If I find them I will post here.

have a good day,
-yoshiro (mark) aoki

Posted: Tue Jan 16, 2007 10:27 pm
by yoshiro aoki
The test cases I posted were in my post right before yours.

I see that my message there has been cut away (removed).

Maybe my posting of that information was not allowed :(

Ok, from memory I can offer only small advice, and that is to be sure to write test cases to check border conditions.

Hope that helps. Now, I must get back to working :-P

Re: 10427 - Naughty Sleepy Boys

Posted: Sun Dec 07, 2008 9:09 pm
by sazzadcsedu
what is the exact input limit for this problem??

my solution works well for <100000000;

but does nt wrk more than that.

can anyone help???

here is my code.

is I/O format ok???

i got TLE;
but why??????

Code: Select all

removed after ACCepted.

Re: 10427 - Naughty Sleepy Boys

Posted: Sun Dec 07, 2008 10:02 pm
by mf
sazzadcsedu wrote:what is the exact input limit for this problem??
You can't read, or what?

The problem statement is very specific about what you should expect in the input:
http://acm.uva.es/p/v104/10427.html wrote:The input will contain one or more line each containing a positive integer N (N<100000000). Total line of the input file will not exceed 11000.
sazzadcsedu wrote:is I/O format ok???
Looks good to me.
sazzadcsedu wrote:i got TLE;
but why??????
Because your program can't solve 11000 test cases in under 3 seconds.

You need to solve each test case much faster, than with a loop with many millions of iterations.

10427 - Naughty Sleepy Boys

Posted: Sun Mar 01, 2009 9:35 pm
by sazzadcsedu
LOts of people give input/output for num>=100000000.
which needn't to be cosidered because problem statement says
The input will contain one or more line each containing a positive integer N (N<100000000).

Re: 10427 - Naughty Sleepy Boys

Posted: Thu Sep 08, 2011 9:10 pm
by plamplam
You can simply solve this using brute force. May be there is a smarter way to get lower runtime but I am too lazy to figure it out as I got Accepted. My code got Accepted in 0.572(not a good runtime but whatever). Just use a character array to precalculate and print the N-th(or (N-1)-th, depending on what you use) index of the array.