Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2012

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: can one make local symbol in a pure function?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg127391] Re: can one make local symbol in a pure function?
  • From: Richard Fateman <fateman at cs.berkeley.edu>
  • Date: Fri, 20 Jul 2012 23:43:20 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • Delivered-to: mathgroup-newout@smc.vnet.net
  • Delivered-to: mathgroup-newsend@smc.vnet.net
  • References: <jub2s2$eid$1@smc.vnet.net>

On 7/20/2012 12:54 AM, Nasser M. Abbasi wrote:
> I was learning a bit about pure functions.
> Suppose we have this toy exa
>
> ---------------------
> lst = {1, 2, 3};
> Map[Function[{x}, a=2; x^a], lst]
> ----------------------

Map[  Function[{x},Module[ ...]  ...
>

I suggest you read Structure & Interpretation of Computer Programs
by Abelson/Sussman

if you want to learn about pure functions.

Mathematica doesn't really have them.  It just has global names that
have peculiar lexicographic appendages.

Try

Module[{a},a]






  • Prev by Date: Re: Solving Third Order differential equation using Mathematica.
  • Next by Date: Re: can one make local symbol in a pure function?
  • Previous by thread: Re: can one make local symbol in a pure function?
  • Next by thread: Re: can one make local symbol in a pure function?