11044 - Searching for Nessy

All about problems in Volume 110. If there is a thread about your problem, please use it. If not, create one with its number in the subject.

Moderator: Board moderators

Post Reply
L I M O N
Learning poster
Posts: 58
Joined: Wed Dec 31, 2003 8:43 am
Location: Dhaka, Bangladesh
Contact:

11044 - Searching for Nessy

Post by L I M O N » Tue Jun 13, 2006 6:32 am

i just print (n/3) * (m/3) and got WA.
Is my algorithm right ??
if Wrong, then anyone please help me to give some ideas.

mf
Guru
Posts: 1244
Joined: Mon Feb 28, 2005 4:51 am
Location: Zürich, Switzerland
Contact:

Post by mf » Tue Jun 13, 2006 8:30 am

just print (n/3) * (m/3) and got WA.
Is my algorithm right ??
Yes, it's correct.

User avatar
emotional blind
A great helper
Posts: 383
Joined: Mon Oct 18, 2004 8:25 am
Location: Bangladesh
Contact:

Post by emotional blind » Tue Jun 13, 2006 4:30 pm

TO LIMON

input

Code: Select all

1
5 5
output

Code: Select all

4
your output

Code: Select all

1

User avatar
Krzysztof Duleba
Guru
Posts: 584
Joined: Thu Jun 19, 2003 3:48 am
Location: Sanok, Poland
Contact:

Post by Krzysztof Duleba » Tue Jun 13, 2006 5:04 pm

I disagree - 1 is the right answer (one sonar in the middle is enough).

User avatar
emotional blind
A great helper
Posts: 383
Joined: Mon Oct 18, 2004 8:25 am
Location: Bangladesh
Contact:

Post by emotional blind » Tue Jun 13, 2006 8:06 pm

Krzysztof Duleba
I agree with you,
My previous post was an example of stupid mistake
sorry

fcsc
New poster
Posts: 3
Joined: Wed Mar 01, 2006 4:33 pm

Post by fcsc » Sun Aug 06, 2006 5:09 pm

Yeah you are getting wrong answer because you have to cast in the div, is not the same (n/3) * (m/3) than ( (int) (n/3)) * ( (int) (m/3))

Good work
____________________________
"Free software for a free society"

Yes!
New poster
Posts: 1
Joined: Tue Nov 13, 2007 6:10 pm
Location: Bangladesh
Contact:

Re: 11044 - Searching for Nessy

Post by Yes! » Fri Mar 27, 2009 9:46 pm

How (n/3) * (m/3) derieved? anyone pls help

Jan
Guru
Posts: 1334
Joined: Wed Jun 22, 2005 10:58 pm
Location: Dhaka, Bangladesh
Contact:

Re: 11044 - Searching for Nessy

Post by Jan » Mon Mar 30, 2009 7:43 pm

Think rows and columns differently.
Ami ekhono shopno dekhi...
HomePage

User avatar
plamplam
Experienced poster
Posts: 150
Joined: Fri May 06, 2011 11:37 am

Re: 11044 - Searching for Nessy

Post by plamplam » Thu Jun 30, 2011 12:08 pm

@LIMON your algorithm is partially correct.
Consider the following cases:

Code: Select all

4
173 2936
8801 807
3403 7068
12 11

Code: Select all

55746
788977
2671704
12
You tried your best and you failed miserably. The lesson is 'never try'. -Homer Simpson

mpmohi
New poster
Posts: 13
Joined: Wed Feb 26, 2014 10:15 pm

Re: 11044 - Searching for Nessy

Post by mpmohi » Thu Apr 24, 2014 3:02 am

I tested the given input-output and my code passed the test... but then I got WA!!
my code =>

Code: Select all

 Error was  for(i=0;i<=testCase;i++)  :D  
Now Where is my mistake ?? :(
Last edited by mpmohi on Sat Nov 22, 2014 11:35 pm, edited 1 time in total.

brianfry713
Guru
Posts: 5947
Joined: Thu Sep 01, 2011 9:09 am
Location: San Jose, CA, USA

Re: 11044 - Searching for Nessy

Post by brianfry713 » Thu Apr 24, 2014 8:34 pm

Try running your code on the sample input.
Check input and AC output for thousands of problems on uDebug!

ssavi
New poster
Posts: 28
Joined: Thu Nov 20, 2014 9:57 pm

Re: 11044 - Searching for Nessy

Post by ssavi » Mon Dec 29, 2014 10:47 am

Jan wrote:Think rows and columns differently.
I don't get this . How it could be implented . can anyone please describe with an example ??
I know I am a Failure Guy . :(

Post Reply

Return to “Volume 110 (11000-11099)”