Re: What parts of picolisp did you have the most trouble understanding?

2018-07-31 Thread Arie van Wingerden
Hi Alex,

Op di 31 jul. 2018 om 17:34 schreef Alexander Burger :

>
> But 'cut' is *not* a destructive function. It does not modify the list in
> any
> way. Only the variable which points to the list is modified.
>

OK. That isn't totally obvious, but of course you are right as shown per
this example:

: (setq X '(1 2 3 4 5 6 7 8))
> -> (1 2 3 4 5 6 7 8)
> : (setq S X)
> -> (1 2 3 4 5 6 7 8)   ; Now S points to same memory location as X
> : (cut 3 'S)
> -> (1 2 3)
> : S
> -> (4 5 6 7 8) ; Now S points to the 4th element of that same memory
> location
> : X
> -> (1 2 3 4 5 6 7 8) ; X still points to the same memory location


Ergo: Alex is totally right :)


> In general, all destructive functions are marked as such in the reference.
>

Good to get some feedback and find out how it *really*  works :)

Thx very much!
   Arie


Re: What parts of picolisp did you have the most trouble understanding?

2018-07-31 Thread Alexander Burger
Hi Arie,

I agree with everything you wrote, except:

> 1. mutability. Operations like 'cut' alter the contents of their
> argument(s). So, it is very important to understand that in PicoLisp
> 'functions' often are not functions in the mathematical sense, because
> there arguments would never be changed by a function.

There are destructive and non-destructive functions in PicoLisp, yes.

But 'cut' is *not* a destructive function. It does not modify the list in any
way. Only the variable which points to the list is modified.

In general, all destructive functions are marked as such in the reference.

♫ Alex

-- 
UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe


Re: What parts of picolisp did you have the most trouble understanding?

2018-07-31 Thread Arie van Wingerden
Hi Bruno,

1. mutability. Operations like 'cut' alter the contents of their
argument(s). So, it is very important to understand that in PicoLisp
'functions' often are not functions in the mathematical sense, because
there arguments would never be changed by a function. For e.g. a Scheme
programmer this can be a real pitfall; in Scheme they often use a ! (like
'set!') in the name of a 'destructive' operation.

2. naming of functions. I often have trouble finding the operation
(function)  I need, because the naming is not so obvious (at least for me
:). With good examples this could be cleared up a bit.

3. concise examples are needed. Only explain one concept at a time; not too
much at once :)

Thanks for your efforts!
   Arie

Op di 31 jul. 2018 om 07:49 schreef Bruno Franco <
brunofrancosala...@gmail.com>:

> three questions:
> 1) what parts of picolisp have you had trouble understanding? Which
> clashed with your previous experience as a programmer?
>
> 2) What features of picolisp are you using right now? Did you learn
> something interesting while using them that you would like others to know?
>
> 3) is there a part that you don't understand yet, but would like to master?
>
> I wanna use the answers to these questions to make tutorials for the wiki.
> To make the learning curve a little easier ;)
>


Re: What parts of picolisp did you have the most trouble understanding?

2018-07-31 Thread O.Hamann

On 31.07.2018 07:41, Bruno Franco wrote:

three questions:
1) Which clashed with your previous experience as a programmer?
The pilog part, I stopped thinking about transferring Prolog LPN 
examples when it came to Prolog list handling ([head | tail])  or 
Context Free Grammars /Definite Clause Grammar,



2) What features of picolisp are you using right now?
picolisp as tiny local application server as clickable frontend for 
local shell scripts.


3) is there a part that you don't understand yet, but would like to 
master?
The database index topic. I'm sure it's obvious if one has knowledge of 
data indexing in general, but I always failed to set up quickly an 
indexable set of data records.


The use of Third Party libraries. It's often mentioned, that (at least 
64bit-) picolisp makes it easy to use available libs written in C, but 
there are few examples I think.


Even don't know, which Libs could be of benefit while using picolisp.


To make the learning curve a little easier ;)


Combining picolisp with a Frontend Framework like bootstrap, AngularJS 
or similar might attract new users - especially for promoting PilBox on 
tablet or smartphone.


--
UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe


What parts of picolisp did you have the most trouble understanding?

2018-07-30 Thread Bruno Franco
three questions:
1) what parts of picolisp have you had trouble understanding? Which clashed
with your previous experience as a programmer?

2) What features of picolisp are you using right now? Did you learn
something interesting while using them that you would like others to know?

3) is there a part that you don't understand yet, but would like to master?

I wanna use the answers to these questions to make tutorials for the wiki.
To make the learning curve a little easier ;)