[blfs-dev] ***SPAM*** Lua can be used as versy simple calculator

Pierre Labastie pierre.labastie at neuf.fr
Sun Jan 25 09:00:30 PST 2015


Le 25/01/2015 14:00, Fernando de Oliveira a écrit :
>[...]
>
> Yesterday I almost include in "Introduction to Lua" the sentence:
> 
> "Lua can also be used as a simple console calculator."
> 
> But I would need to write somewhere in the text info on how to use it.
> The tutorial in the wiki is very good, I reproduced part of it above.
> However it is for Lua-5.2, which needed an "=" sign before each
> mathematical operation. In Lua-5.3, "no need to prefix with '='".
> 
> Unsure about what to do, I omitted this in the update.
> 
> I think it is worth including something in the page, but would like to
> have opinions and some help about where and what to include in the text.
> 
> Of course, if there is no reply, I assume that the page should be left
> as is now.
> 

Just my opinion here. The first item might have to be discussed more widely
among other editors, the second is more of a personal view:
- It is always tempting to write some information about how to _use_ installed
software, but I think it is not the aim of the book, unless this information
is critical for security and/or system stability. The book is about how to
_install_ software.
- It may be interesting to signal some uncommon use of software, in the
introduction and/or in the "Configuring" section. But a lot of languages have
the possibility to be used as calculators (Perl and Python come to mind), so
that is not uncommon (actually, all interpreted languages have this ability).
Maybe a better way to state what you mean is to say that Lua can be either
interpreted or compiled (actually, that's the difference between lua and luac)

Regards
Pierre


More information about the blfs-dev mailing list