|
|
Environment model
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
I am a beginner in Scheme. I'm given the following example:
==
((lambda (x) (* x x))
((lambda (a b) (a (* b b)))
(lambda (a) (* a a))
(* 2 2)))
==
and the computed value is 65536. Could someone explain me step by step
why the value is this one?
Thanks.
- --
Merciadri Luca
See http://www.student.montefiore.ulg.ac.be/~merciadri/
- --
Failure is not falling down, you fail when you don't get back up.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.8 <http://mailcrypt.sourceforge.net/>
iEYEARECAAYFAk838XEACgkQM0LLzLt8MhzoFwCglHm+XJFob2rWXIvLlOx70tz9
nn0AnArY+xWvFtb5xK0FnKeJ7KlLE27T
=aK1Z
-----END PGP SIGNATURE-----
|
|
0
|
|
|
|
Reply
|
Luca.Merciadri (232)
|
2/12/2012 5:05:53 PM |
|
Merciadri Luca wrote:
> ((lambda (x) (* x x))
> ((lambda (a b) (a (* b b)))
> (lambda (a) (* a a))
> (* 2 2)))
> and the computed value is 65536. Could someone explain me
> step by step why the value is this one?
It is not difficult. This (* 2 2) evaluates to 4, and after
that what is it that you do not understand?
Which Scheme implementation are you using? If I
understand correctly, Racket has a step-by-step evaluator
that could help you.
--
Marco Maggi
|
|
0
|
|
|
|
Reply
|
marco9664 (30)
|
2/12/2012 7:46:08 PM
|
|
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I've now understood. Thanks.
- --
Merciadri Luca
See http://www.student.montefiore.ulg.ac.be/~merciadri/
- --
It is better to die on one's feet than live on one's knees.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.8 <http://mailcrypt.sourceforge.net/>
iEYEARECAAYFAk84NzoACgkQM0LLzLt8Mhzk/ACbBfMDj2CX+VW5/9aeRnOUudzp
3DMAnRl1XjWCGIqhWuL3JseMvdOQ6aWe
=C4np
-----END PGP SIGNATURE-----
|
|
0
|
|
|
|
Reply
|
Luca.Merciadri (232)
|
2/12/2012 10:03:38 PM
|
|
|
2 Replies
66 Views
(page loaded in 0.067 seconds)
Similiar Articles: Environmental variables to point at libraries with Modelsim ...... Xilinx libraries, and I put them in the directory defined by the $XILINX environment ... environmental variable and use this in Modelsim.ini, the way the $Model_Tech ... Model selection in Proc Mixed - comp.soft-sys.sasI am wondering whether or not SAS is the best environment to perform model selection, and I plan on calculating AIC values manually as a check. agent-based modelling with Matlab - comp.soft-sys.matlab ...But it does a good job of modeling different agents which each have a pilot doing ... comp.graphics.api.opengl announcement: breve 2.2.1, agent based simulation environment ... difference between Fire 240 and Netra 240 - comp.unix.solaris ...some application provider is strictly asking for Netra model, although doesn't specify why Netra is mandatory (since it is only a pilot and not production environment). SimMechanics Link - Univeral Joints - comp.soft-sys.matlab ...I've found that it is quite straightforward and extremely convenient for me to create my complex multi-body models in a CAD environment and then obtain the physical model ... Env variables in ooRexx & XP? - comp.lang.rexxIn general, on operating systems that provide a Unix-like process model, if you set an environment variable, it affects only the process in which it's set and its child ... real-time object tracking using optical flow / XY coordinates ...... objects,,,,it works well and track moving objects only in the environment,,now i want to know their coordinates on the simulink output video,,,i tried this: on the model ... Java 64bit client VM Not supported - comp.unix.solarisI just installed a new Java Environment 1.4.2_06 release,everything installed correctly. ... java -help sais "use a 64-bit data model if available". It is obviously not (yet ... Simulating a knurl on Drawing - comp.cad.solidworksAnd if you want to show the actual, then you'll have to model the knurl. ... SP4.1 SW2007 SP5.0 http://gupta9665.wordpress.com/ "Please consider the environment ... How to normalize a signal using Simulink?? - comp.soft-sys.matlab ...Hi all, I would like to normalize signal from a simulink model but I don't know how to do it. I have tried to embedd the next function: function... Model Environment - ModelCRV for Seeds. Dockwalkers. Do's and Don'ts Open-system environment reference model - Wikipedia, the free ...Open-system environment (OSE) reference model (RM) or OSE reference model (OSE/RM) is one of the first reference models for enterprise architecture. It provides a ... 7/23/2012 10:41:01 AM
|
|
|
|
|
|
|
|
|