lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Steve Litt <slitt@troubleshooters.com> writes:

> On Tue, 14 May 2013 21:10:57 -0400
> Steve Litt <slitt@troubleshooters.com> wrote:

...

> Serious bummer. When you copy from the PDF version and paste into a
> text file, the result is gibberish characters.

Copying from pdf worked for me. At least, there was no gibberish,
although the indentation was lost.

I used Foxit Reader on Windows, pasting to an Emacs buffer:

-- defines a factorial function
function fact (n)
if n == 0 then
return 1
else
return n * fact(n-1)
end
end
print("enter a number:")
a = io.read("*n") -- reads a number
print(fact(a))

It might not be deliberate obfuscation, but an incompatibility between
the pdf generator and reader software.

--
Brian Casiello <bcasiello@gmail.com>