Page 2 of 2
Posted: Wed Oct 04, 2006 7:52 am
by 4cm2
Im also stuck on 337
my code is working for the test cases and also any weird inputs that I can think of, but still WA
sample inputs would be a big help here
Posted: Wed Oct 04, 2006 7:53 am
by 4cm2
Im also stuck on 337
my code is working for the test cases and also any weird inputs that I can think of, but still WA
sample inputs would be a big help here
Posted: Wed Oct 04, 2006 8:17 am
by pankaj trivedi
If you need output for some of your inputs ,I can provide it to you.
Posted: Wed Oct 04, 2006 9:09 am
by 4cm2
Could you try this input and post the correct output?
I tried to use every feature of the program
thanks
5
^i^^^^123
^57^^^b^^
^88^d^d^d^bhello
^62^u^^^r45^e
^h^r^r^r^r^r45
6
^i^^^^123
^57^^^b^^
^88^d^d^d^bhello
^62^u^^^r45^e
^h^r^r^r^r^r45
0
Posted: Wed Oct 04, 2006 11:15 am
by pankaj trivedi
My accepted code gives the following output for your input:
Code: Select all
Case 1
+----------+
|123^ 45 |
| |
| |
| |
| |
|^ ^45 ^ |
| |
| |
| |
|hello |
+----------+
Case 2
+----------+
|123^ 450 |
| |
| |
| |
| |
|^ ^45 ^ |
| |
| |
| |
|hello |
+----------+
Different output
Posted: Wed Nov 01, 2006 12:02 pm
by thurbo
Hmmm,
My program just got accepted but gives a different output on this test input. (Please note that there is an error in your test input, it says that there will be 6 more lines of input. This will include the 0, not sure if that is what you meant).
My output is as follows:
Code: Select all
Case 1
+----------+
|^^12345 |
| |
| |
| |
| |
|^ ^ 45 |
| |
| |
| |
|hello |
+----------+
Case 2
+----------+
|^^12345 0 |
| |
| |
| |
| |
|^ ^ 45 |
| |
| |
| |
|hello |
+----------+
Take for example line 4 in either one of the testcases.
^62: go to position 6, 2
^u: go to position 5, 2
^^: insert ^ (5, 2), go to position 5, 3
^r: go to position 5, 4
4: insert 4 (5, 4), go to position 5, 5
5: insert 5 (5, 5), go to position 5, 6
In my opinion there should be a space between ^ and 4.
Jeroen