Thanks for the update.
Hilaire
--
Dr. Geo
http://drgeo.eu
"Atharva Khare" <mailto:khareatha...@gmail.com>>
To: "Any question about pharo is welcome" <mailto:pharo-users@lists.pharo.org>>
Sent: 15.5.2019 15:26:11
Subject: Re: [Pharo-users] Bloc of code in tiers programming language
Hey,
I think in python, you use Lamb
Hi Ted,
On 17/05/19 6:38 p. m., Brainstorms wrote:
> Hi Offray,
>
> Yes, I definitely agree with you that Lua does not have the nice development
> environment of Pharo (what other language does?), and is very bare-bones, as
> it was originally intended for embedded applications.
Yep, Pharo and
Hi Offray,
Yes, I definitely agree with you that Lua does not have the nice development
environment of Pharo (what other language does?), and is very bare-bones, as
it was originally intended for embedded applications. I've gone through
nearly all of the online version of the Pharo MOOC now, and
Hi t,
Yes, I know that Lua support OOP, with several implementations and using
metatables. I have not looked in detail. But the idea of shared
similarities while being at opposite extremes of the programming
spectrum/experience is more related with both sharing minimalist
concepts applied everywhe
Hi Offray,
You probably know that you can develop Lua using OOP techniques, so they're
not so opposite for me, at least. There is a significant difference as far
as their OOP styles, however: Lua OOP is prototype-based, not class-based.
But you can fashion class(like) objects in Lua and progra
Hi,
Is nice to see this similitude between Lua and Pharo. We have been using
both in the Grafoscopio[1] project, because Lua is Pandoc's default
choice for embedded scripting language, and is pretty fast on the
Abstract Syntax Tree filters.
[1] https://mutabit.com/grafoscopio/index.en.html
For m
Richard O'Keefe wrote
> I did not mean "course of instruction on the topic of continuations",
> I meant "that class whose name is Continuation in the Smalltalk image."
> In a Playground, type Continuation and then Control-B.
Of course... My inexperience again, coupled with hopes for a course of
i
I did not mean "course of instruction on the topic of continuations",
I meant "that class whose name is Continuation in the Smalltalk image."
In a Playground, type Continuation and then Control-B.
On Fri, 17 May 2019 at 14:03, Brainstorms wrote:
> Richard O'Keefe wrote
> > Blocks in current Sma
Richard O'Keefe wrote
> Blocks in current Smalltalk system are just like lambdas in Scheme.
> Pharo even has continuations (see the Continuation class).
I was going to ask about coroutines and continuations, but I thought maybe
bringing these subjects up in another thread would be more appropriate
Blocks in current Smalltalk system are just like lambdas in Scheme.
Pharo even has continuations (see the Continuation class).
On Fri, 17 May 2019 at 05:21, Brainstorms wrote:
> I beg your pardon.. and thank you for being the first to draw my attention
> to
> the fact that the phrase (a common
You got it. Thanks, Ben!
After success with Lua, now I'm thinking about how to get Pharo inserted
into the culture here...
Ben Coman wrote
> You mean like this...
>
> In System Browser...
> Object subclass: #A
> instanceVariableNames: ''
> classVariableNames: ''
> package: 'AA'
>
> A
On Fri, 17 May 2019 at 01:21, Brainstorms wrote:
> I beg your pardon.. and thank you for being the first to draw my attention
> to
> the fact that the phrase (a common enough American colloquialism) is
> actually a logical fallacy. Until now, it's been strictly idiomatic to me.
>
> And thank you
I beg your pardon.. and thank you for being the first to draw my attention to
the fact that the phrase (a common enough American colloquialism) is
actually a logical fallacy. Until now, it's been strictly idiomatic to me.
And thank you for your prompt reply.
Am I safe to assume that blocks in
I do wish people wouldn't say "beg the question"
https://grammarist.com/rhetoric/begging-the-question-fallacy/
when they mean "invites" or "raises" the question. Sigh.
Yes, Smalltalk is just like Lua here.
|f g| "declare f and g as local variables"
f := [... g value ...]. "f uses g's current
Richard,
Question from someone still fairly new to Smalltalk:
To implement the example you gave regarding mutually recursive functions in
Lua, one must write something like this:
local f, g
function g ()
f()
end
function f ()
g()
end
where the
Suppose you want a pair of mutually recursive functions.
They have to be able to name each other.
In languages like Python and Ruby, you can have
methods AND you can have named functions. In fact
Python had named functions before it had objects.
But in Smalltalk, you have methods, which cannot be
Hi,
Blocks are very useful when you need to evaluate code from an outside
source.
For example a BPM Process that have gateways with different conditions.
To the Smalltalk system conditions come as Strings and convert them to
Smalltalk objects is very easy:
self evaluate: '[:process | process amou
On Wed, May 15, 2019 at 5:21 PM Tim Mackinnon wrote:
>
> On a similar line - I’ve often noticed that an interesting block pattern in
> Smalltalk which is overlooked in other languages is how we handle errors
> through them.
>
> We often don’t throw exceptions but instead pass a useful block (and
On a similar line - I’ve often noticed that an interesting block pattern in
Smalltalk which is overlooked in other languages is how we handle errors
through them.
We often don’t throw exceptions but instead pass a useful block (and often 2)
for what to do instead.
at:ifAbsent: comes to mind or
Le 15/05/2019 à 20:37, Konrad Hinsen a écrit :
> Lambda expressions are indeed Python's anonymous functions, but no
> Python programmer would create a lambda expression only to assign it
> to a variable. Doing this in an article to "sell" Smalltalk might well
> have the opposite effect.
Nor a Smal
Am 15.05.19 um 15:26 schrieb Atharva Khare:
I think in python, you use Lambda Expressions. Here is how I would do it
in python3:
import math
f = lambda x: math.cos(x) + x
d_f = lambda x: (f(x + 1e-8) - f(x)) * 1e8
Lambda expressions are indeed Python's anonymous functions, but no
Python prog
Here's a nice description about JS:
https://www.vinta.com.br/blog/2015/javascript-lambda-and-arrow-functions/
Best wishes,
Tomaz
-- Original Message --
From: "Hilaire"
To: pharo-users@lists.pharo.org
Sent: 15.5.2019 18:54:58
Subject: Re: [Pharo-users] Bloc of code in ti
Hi,
It is an important restriction on Python. So Javasctip has several way
of doing lambda, correct?
Thanks
Hilaire
Le 15/05/2019 à 16:19, Richard O'Keefe a écrit :
> One point worth making is that Python lambdas are artificially restricted:
> the body of a Python lambda may only be a single ex
Thanks guys.
--
Dr. Geo
http://drgeo.eu
One point worth making is that Python lambdas are artificially restricted:
the body of a Python lambda may only be a single expression, not a sequence
of statements. This restriction is for ideological reasons (the BDFL does
not *want* you to do that) not for technical reasons. Lisp and Algol 68
Subject: Re: [Pharo-users] Bloc of code in tiers programming language
Hey,
I think in python, you use Lambda Expressions. Here is how I would do
it in python3:
import math
f = lambda x: math.cos(x) + x
d_f = lambda x: (f(x + 1e-8) - f(x)) * 1e8
On Wed, May 15, 2019 at 6:33 PM Hila
Hey,
I think in python, you use Lambda Expressions. Here is how I would do it in
python3:
import math
f = lambda x: math.cos(x) + x
d_f = lambda x: (f(x + 1e-8) - f(x)) * 1e8
On Wed, May 15, 2019 at 6:33 PM Hilaire wrote:
> Hi,
>
> We, Smalltalkers, use bloc of code as easily as we breathe ai
Hi,
We, Smalltalkers, use bloc of code as easily as we breathe air.
I am writing an article on Smalltalk programming for a French
mathematics teachers magazine.
To illustrate the simplicity of Smalltalk, I would like to compare how
the bloc of code 'f' and 'df' below will be implemented in Javas
29 matches
Mail list logo