11360 - Have Fun with Matrices

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

Moderator: Board moderators

User avatar
Mata
New poster
Posts: 18
Joined: Mon Dec 17, 2007 11:35 pm
Location: Queretaro
Contact:

11360 - Have Fun with Matrices

Post by Mata » Mon Dec 17, 2007 11:40 pm

Hi, I try to solve this problem and I got wa.
I get correct output with the sample input, can any one post some input to see if i can find my mistake.
thanks.

User avatar
sohel
Guru
Posts: 856
Joined: Thu Jan 30, 2003 5:50 am
Location: New York

Post by sohel » Tue Dec 18, 2007 9:44 am

1. Have you considered % 10
2. Check your output format carefully(there is a blank line after last case too)

I can't think of any other critical case!

User avatar
Mata
New poster
Posts: 18
Joined: Mon Dec 17, 2007 11:35 pm
Location: Queretaro
Contact:

Post by Mata » Tue Dec 18, 2007 7:13 pm

I check my code and I think it works fine, I considered the case, and print the blank line at the end of every case, i submited my code again and i got In judge queue what is it?, here is my code:

Code: Select all

I got Ac

Saul Hidalgo
New poster
Posts: 18
Joined: Wed Jan 03, 2007 2:36 am
Location: Los Teques, Venezuela

Post by Saul Hidalgo » Mon Dec 31, 2007 10:21 am

Hi! I have too WA and i take carefully with the blank line after last case, and i proof with matrices of size 1 and nothing, WA. :-?

Here is my code for that somebody can help me.

thanks to all. :P

Code: Select all

Code Cutted, In my post of below is the file updated 
Last edited by Saul Hidalgo on Tue Jan 01, 2008 1:06 am, edited 1 time in total.

User avatar
sohel
Guru
Posts: 856
Joined: Thu Jan 30, 2003 5:50 am
Location: New York

Post by sohel » Mon Dec 31, 2007 11:05 am

You have to print an extra blank line after the last case too.

Output format
Case #1
----
----
----
----
blank line
Case #2
---
---
---
blank line

Saul Hidalgo
New poster
Posts: 18
Joined: Wed Jan 03, 2007 2:36 am
Location: Los Teques, Venezuela

Post by Saul Hidalgo » Tue Jan 01, 2008 12:58 am

Hi! very thaks for answer me :) :) But, I tried without the last line and i have WA again. :cry: . Here is the new code without the last blank line.

Code: Select all

 Code AC
Last edited by Saul Hidalgo on Tue Jan 01, 2008 2:42 pm, edited 1 time in total.

User avatar
rio
A great helper
Posts: 385
Joined: Thu Sep 21, 2006 5:01 pm
Location: Kyoto, Japan

Post by rio » Tue Jan 01, 2008 4:19 am

Sohel said:
You have to print an extra blank line after the last case too.
Re-read the problem description. It says:
Print a blank line after each case (even after the very last one).
-----
Rio

Saul Hidalgo
New poster
Posts: 18
Joined: Wed Jan 03, 2007 2:36 am
Location: Los Teques, Venezuela

Post by Saul Hidalgo » Tue Jan 01, 2008 2:40 pm

Hi to all! Really sorry me please. I have a mistake reading your help. :oops: :oops: Thanks, Very thanks. :wink: :wink: . I got AC.
About the code. I think cut. Thanks to Rio and Sohel for help me.

lnr
Experienced poster
Posts: 141
Joined: Sat Jun 30, 2007 2:52 pm
Location: Dhaka,Bangladesh

Re: 11360 - Have Fun with Matrices

Post by lnr » Fri Jun 20, 2008 8:02 am

Code: Select all

Code Removed
Last edited by lnr on Fri Jun 20, 2008 4:19 pm, edited 1 time in total.

User avatar
sohel
Guru
Posts: 856
Joined: Thu Jan 30, 2003 5:50 am
Location: New York

Re: 11360 - Have Fun with Matrices

Post by sohel » Fri Jun 20, 2008 11:06 am

Input

Code: Select all

1
3
123
456
789
1
col 1 2
Your code gives the wrong output for the above case!
You haven't implemented the exchanges of columns correctly.

When you get wrong answer, try to test with some inputs of your own.
Think of the obvious cases first.

lnr
Experienced poster
Posts: 141
Joined: Sat Jun 30, 2007 2:52 pm
Location: Dhaka,Bangladesh

11360 - Have Fun with Matrices

Post by lnr » Fri Jun 20, 2008 4:56 pm

Removed

saiful_sust
Learning poster
Posts: 97
Joined: Fri Aug 22, 2008 10:18 pm
Location: CSE.SUST.SYLHET

Re: 11360 - Have Fun with Matrices

Post by saiful_sust » Mon Dec 29, 2008 5:25 pm

Mata wrote:Hi, I try to solve this problem and I got TLE.
can any one help me????????
I get correct output with the sample input
thanks.in advance

here is my code


CUT after ACC.............

:D
Last edited by saiful_sust on Mon Jun 01, 2009 9:24 pm, edited 1 time in total.

Obaida
A great helper
Posts: 380
Joined: Wed Jan 16, 2008 6:51 am
Location: (BUBT) Dhaka,Bagladesh.

Re: 11360 - Have Fun with Matrices

Post by Obaida » Wed Jan 07, 2009 8:27 am

Help me i got wa :(

Code: Select all

code removed
Last edited by Obaida on Mon Jun 08, 2009 9:39 am, edited 1 time in total.
try_try_try_try_&&&_try@try.com
This may be the address of success.

Obaida
A great helper
Posts: 380
Joined: Wed Jan 16, 2008 6:51 am
Location: (BUBT) Dhaka,Bagladesh.

Re: 11360 - Have Fun with Matrices

Post by Obaida » Thu Jan 29, 2009 11:01 am

Some 1 plz help!!! :(
try_try_try_try_&&&_try@try.com
This may be the address of success.

MRH
Learning poster
Posts: 51
Joined: Mon Aug 11, 2008 9:09 pm

Re: 11360 - Have Fun with Matrices

Post by MRH » Thu Jan 29, 2009 11:48 am

Do not use %ld & %c in a same code
use gets() & parsing it by ssacnf()

REPLACE getchar() & %c

hope now acc

Post Reply

Return to “Volume 113 (11300-11399)”