Page 1 of 1

10403 - Escape from Tut's Tomb

Posted: Tue Nov 26, 2002 11:08 pm
by makbet
does ac=b mean a+c=b
if so, why isn't
a=1
b=2
c=1
the correct anwser for the
sample input:
3 5
ac=b
ac=b //does repeating have any effect?
bc>a
ac=b
c<ab
:o

Re: 10403: sample input

Posted: Wed Nov 27, 2002 5:02 pm
by Robbie
Yes , I think ac=b means a+c=b
But n gold sphinxes have distinct interger weights 1..n. So the correct answer here is : 1 3 2

This problem seems so tricky . Could anyone give me a hint ?
thanx

Posted: Thu Nov 28, 2002 6:00 am
by dwyak
can your program deal with this case?

1 1
A >

this makes me WA in the contest.

Posted: Sat Feb 01, 2003 12:19 pm
by Pasq
And wlt should be the output ???

Posted: Fri Mar 14, 2003 3:58 pm
by przygoda
it is possible to use capital letters ???

10403 Escape from Tut's Tomb I/O

Posted: Mon Jan 12, 2004 8:41 pm
by Per
I'm getting WA. Could anyone check these inputs please?

Code: Select all

1 1
a <
1 1
a >
2 1
< a b
2 1
a = b
2 1
a > b
24 1
o b v k p h t s f e w u j q n x < m d g i a c r l 
24 2
r j l i x s o f g e p v = u n c a q t b h k m w d
o b v k p h t s f e w u j q n x < m d g i a c r l 
19 3
n s i k o q r g h m p d j > b l e c a f 
s j f l a n g k q b m c i > o d e h r p 
m e b j s l h p f r q n g < c i k o a d 
19 4
n s i k o q r g h m p d j > b l e c a f 
s j f l a n g k q b m c i > o d e h r p 
m e b j s l h p f r q n g < c i k o a d 
q a n c s m k p r h l g d < b f e i o j
My output is:

Code: Select all

No solution possible!
Solution: 1
Solution: 1 2
No solution possible!
Solution: 2 1
Solution: 4 1 18 19 2 3 20 5 21 6 7 22 23 8 9 10 11 24 12 13 14 15 16 17
Solution: 4 1 18 19 2 3 20 5 21 6 7 22 23 11 8 9 14 24 10 15 16 12 17 13
Solution: 11 1 15 16 2 3 4 5 17 6 18 7 8 9 19 10 12 13 14
No solution possible!

Posted: Tue Jan 13, 2004 4:48 pm
by Adrian Kuegel
I get the same answer on your test cases.
What about:
1 1
a =
2 1
a = b
3 1
a b = c
4 1
a b = c d
5 1
a b c = d e
6 1
a b c = d e f
7 1
a b c d = e f g
8 1
a b c d = e f g h
Output should be:
No solution possible!
No solution possible!
Solution: 1 2 3
Solution: 1 4 2 3
No solution possible!
No solution possible!
Solution: 1 2 4 7 3 5 6
Solution: 1 2 7 8 3 4 5 6

Posted: Tue Jan 13, 2004 9:39 pm
by Per
Thanks. I handled those cases correctly, but I found my mistake: I had made the really stupid assumption that there could never be two different equalities!

I.e. I failed to handle cases such as:

Code: Select all

8 2
a b c d = e f g h
e f c d = a b g h
where the answer is

Code: Select all

Solution: 1 4 5 8 2 3 6 7

Posted: Mon Aug 20, 2007 12:37 pm
by shanto86
hint plz