## 177 - Paper Folding

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

Moderator: Board moderators

Raiyan Kamal
Experienced poster
Posts: 106
Joined: Thu Jan 29, 2004 12:07 pm
Contact:
You have to extract the hints from the given paragraph. Try to figure/find out the meaning of the words and phrases unkown / not very familiar to you. Then you'll be able to solve it the way I did.

But that is not the only way, I believe you can solve it in many other ways. You might find another solution to this problem too. In that case, I would really like to exchange ideas with you regarding this problem.

daveon
Experienced poster
Posts: 229
Joined: Tue Aug 31, 2004 2:41 am
Actually, generating the output was just as challenging as solving it.

Raiyan Kamal
Experienced poster
Posts: 106
Joined: Thu Jan 29, 2004 12:07 pm
Contact:
congrats !

daveon
Experienced poster
Posts: 229
Joined: Tue Aug 31, 2004 2:41 am
By the way, I solved this problem just before I posted my hint.
But here is the hint expanded all the way:

Code: Select all

``````N=1 -> RU
N=2 -> RULU
N=3 -> RULULDLU
N=4 -> RULULDLULDRDLDLU
``````

mistycheney
New poster
Posts: 6
Joined: Sat Sep 29, 2007 11:11 am

### How could we output when N>10??

When N<=10, my output is fine..
but when it comes to 11,12,13, the screen is messy, how could i tell whether it's right or wrong?

Jan
Guru
Posts: 1334
Joined: Wed Jun 22, 2005 10:58 pm
Contact:
You can save your output to a file.
Ami ekhono shopno dekhi...
HomePage

mistycheney
New poster
Posts: 6
Joined: Sat Sep 29, 2007 11:11 am

### why PE?

Don't know why keep getting PE, i outputed the result to file and checked every 13 curves~~I think they're perfect~~
Could anyone help me?~~
Thanks very much~~
--------------------------------------------------
Last edited by mistycheney on Wed Oct 10, 2007 7:54 am, edited 1 time in total.

Jan
Guru
Posts: 1334
Joined: Wed Jun 22, 2005 10:58 pm
Contact:
While sending your code make sure that your code prints to the standard output.[I told you to save your output to a file, such that you can check it maually]

However, check the input output carefully.

Input:

Code: Select all

``````5
0``````
Output:

Code: Select all

``````....._..._
....|_|_|.|_
._..._|...._|
|_|_|_
..|_|_|
....|_
....._|
..|_|
^``````
Where '.' represents a space. Hope it helps.
Ami ekhono shopno dekhi...
HomePage

mistycheney
New poster
Posts: 6
Joined: Sat Sep 29, 2007 11:11 am
thanks so much~~like what you said, my mistake was that i outputed extra spaces after those shorter lines in each curve~~
now I got AC~~thank you~~

Jan
Guru
Posts: 1334
Joined: Wed Jun 22, 2005 10:58 pm
Contact:
You are welcome. Don't forget to remove your code, thanks.
Ami ekhono shopno dekhi...
HomePage

frimlik
New poster
Posts: 3
Joined: Sat Oct 04, 2014 11:14 pm

### Re: 177 - Paper Folding

Could anybody (with AC code), please, paste here an output made from input
1
2
3
4
5
6
7
8
9
10
11
12
13
0
?

Thanks a lot

lighted
Guru
Posts: 587
Joined: Wed Jun 11, 2014 9:56 pm
Location: Kyrgyzstan, Bishkek

### Re: 177 - Paper Folding

Check your input here. http://www.udebug.com/UVa/177
A person who sees the good in things has good thoughts. And he who has good thoughts receives pleasure from life... Bediuzzaman

frimlik
New poster
Posts: 3
Joined: Sat Oct 04, 2014 11:14 pm

### Re: 177 - Paper Folding

Thanks a lot , that's what I've been looking for.
But it didn't solve my problem... Diff says that there is no difference between my output and output from uDebug, but I still get the answer WA...

lighted
Guru
Posts: 587
Joined: Wed Jun 11, 2014 9:56 pm
Location: Kyrgyzstan, Bishkek