348 - Optimal Array Multiplication Sequence

All about problems in Volume 3. 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
rio
A great helper
Posts: 385
Joined: Thu Sep 21, 2006 5:01 pm
Location: Kyoto, Japan

Post by rio » Thu Jan 11, 2007 6:46 pm

Just compare your output and samples output carefully. You will know why.
Last edited by rio on Thu Jan 11, 2007 7:24 pm, edited 1 time in total.

sumantbhardvaj
New poster
Posts: 19
Joined: Sun Jun 18, 2006 4:07 pm
Contact:

Post by sumantbhardvaj » Thu Jan 11, 2007 8:05 pm

Thanx rio ... on carefully watching at my output .. i found tht i had used capital X instead of small X

Tommy Wu
New poster
Posts: 6
Joined: Tue Jan 23, 2007 12:32 pm
Location: Kaousiung,Taiwan
Contact:

Post by Tommy Wu » Sat Jul 07, 2007 6:59 am

Your code fails the follow inputs:

Code: Select all

10
2 84
84 66
66 8
8 410
410 8
8 96
96 10
10 200
200 10
10 2
10
2 64
64 8
8 55
55 333
333 44
44 887
887 554
554 1
1 226
226 33
0
Output should be:

Code: Select all

Case 1: (((A1 x A2) x A3) x (A4 x (A5 x (A6 x (A7 x (A8 x (A9 x A10)))))))
Case 2: ((A1 x (A2 x (A3 x (A4 x (A5 x (A6 x (A7 x A8))))))) x (A9 x A10))

aeiou
New poster
Posts: 21
Joined: Wed May 07, 2008 11:32 am

348 - Optimal Array Multiplication

Post by aeiou » Wed May 28, 2008 2:28 pm

ACed...
Thanks anyway...

kawsar
New poster
Posts: 12
Joined: Thu Aug 05, 2010 7:40 pm

348 WA

Post by kawsar » Sat Aug 07, 2010 1:27 pm

I got accepted....bye.:):):):):):)
Last edited by kawsar on Sat Aug 14, 2010 8:46 pm, edited 1 time in total.

kawsar
New poster
Posts: 12
Joined: Thu Aug 05, 2010 7:40 pm

Re: 348: Why am i getting wrong answer?

Post by kawsar » Sat Aug 14, 2010 8:44 pm

Thanks......,
Mr. Tommy Wu

For your simple input output, i found my mistake in my program.
Thanks a lot.....
Bye.

kawsar
New poster
Posts: 12
Joined: Thu Aug 05, 2010 7:40 pm

Re: 348 WA

Post by kawsar » Sat Aug 14, 2010 8:45 pm

I got accepted......:):)

Mukit Chowdhury
Learning poster
Posts: 98
Joined: Fri Aug 17, 2012 9:23 pm
Location: Dhaka
Contact:

Re: 348 WA

Post by Mukit Chowdhury » Thu Oct 17, 2013 8:37 pm

Getting RE !!! Can anyone give me a suggestion please ????

Code: Select all

Deleted after Accepted...

Post Reply

Return to “Volume 3 (300-399)”