Re: borges' library
- From: "Chris Uppal" <chris.uppal@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: 11 Oct 2006 08:47:20 GMT
mensanator@xxxxxxx wrote:
each book is 410 pages each page has 40 lines and each line 80
characters.
Wait a minute, 80 is more than 25! Or did you originally
mean 80 character words from a 25 character alphabet?
Or maybe all the 25 character words run together and
broken at 80 character intervals?
You've seen a book, yes ? If so then surely you can guess the guy's
meaning without all this blather.
Anyway, for the OP. Here's one way:
Start with a book of all 'a's.
aaaa ... 1311992 chars elided ... aaaa
"Increment" the character at the last position:
aaaa ... 1311992 chars elided ... aaab
That's your second book. Repeat, incrementing that character, until
aaaa ... 1311992 chars elided ... aaaz
(or maybe the last character is ' ', space -- doesn't matter). At that
point you wrap around at that postion, and "carry" into the next column
aaaa ... 1311992 chars elided ... aaba
Keep on incrementing the last position until it wraps again, at which
time you carry again:
aaaa ... 1311992 chars elided ... aabb
....
aaaa ... 1311992 chars elided ... aabz
aaaa ... 1311992 chars elided ... aaca
Keep going, and eventually you'll wrap in the second-last column, so
carry again:
aaaa ... 1311992 chars elided ... abaa
Keep going for another 2e1834097 or so iterations, until you reach:
zzzz ... 1311992 chars elided ... zzzz
Then stop.
-- chris
.
- References:
- borges' library
- From: avery
- Re: borges' library
- From: mensanator@xxxxxxx
- borges' library
- Prev by Date: Re: Question for the pros about project management.
- Next by Date: Re: bison and malloc
- Previous by thread: Re: borges' library
- Next by thread: Re: borges' library
- Index(es):
Relevant Pages
|