You'll enjoy this:
http://norvig.com/21-days.html
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
...
For the curious, the other peeve is:
def function(...
if expression:
return True
else:
return False
instead of:
def function(...
return expression
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
the
student at 80% correct in several kinds of subject areas. The
learning rate they found on those systems was substantially greater
than one grade-level per year without extra contact hours.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu
to get a small display going. Really easier than
most 2-D packages I've seen to start with, and you get to roll it
around. If you are at PyCon, talk to Kirby about his experiences
using it in his classes.
/Linda
--
-- Scott David Daniels
[EMAIL PROTECTED
less than simple.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
of (and
returning) functions. I would think generators belong fairly soon
after functions of functions.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
Kirby Urner wrote:
Again, I think you're probably right, that this particular example is
perverse. Edu-sig is a scratch pad for bad ideas too. :-D
Sorry, Kirby, I see we all seemed to jump on top of you here.
--Scott David Daniels
[EMAIL PROTECTED
to lose this no magic here by side-tracking C to an extended exercise.
I'd put it in an architecture class, perhaps. At least C (and
preferably some native assembly) code should be early in a curriculum,
but certainly CS101 is not the time.
--Scott David Daniels
[EMAIL PROTECTED
need to tell us what yu are interested in / would like to do.
Do you want to find eigenvectors? Do you want to do GUI work?
--
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman
tests for new behavior, watch them fail, and fix the source
until it works.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
because it
is far from obvious when you have enough rigor and when you don't.
Math, to them, seems like a game with a few rules missing.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo
poetry;
you read a bit, reflect a lot, and then read a bit more.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
of practical and enough theory to steer
it. He is also one of the few practical programming authors to
write about how to write in SQL without picking a single vendor and
teaching you how to use their product.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu
to teach in that you need to go slowly -- the changes made
by inheritance take a while to get.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
* self.a * self.c))
self.C = math.acos((self.a**2 + self.b**2 - self.c**2)
/ (2.0 * self.a * self.b))
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
[EMAIL PROTECTED]
http://mail.python.org/mailman
.
If you want to keep anything as properties, I'd keep the ones those
properties with the least dynamic nature.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
[EMAIL PROTECTED]
http://mail.python.org/mailman/listinfo/edu-sig
of assignments where the requirements swerve, showing
the value of malleability in code design.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
of decoupling an API from its current implementation.
I do claim it provides another tool to express a properly decoupled
API.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
game
(2) single game with observers
(3) game with observers w/o enough info to cheat by players.
(4) multi-game server.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman
of systems
programming style programming.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
implementation
show through too much.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
self._active.radius = value
You could read up on __getattr__, __getattribute__, and friends in
the Language References section 3.3.2:
Customizing attribute access
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig
Arthur wrote:
Scott David Daniels wrote:
[EMAIL PROTECTED] wrote:
I think teaching programming outside a context - as an abstract
discipline - is unavoidably problematic in this regard.
I would have more sympathy if you would subscribe to the same philosophy
for geometry and mathematics
with their gut? It is one thing to
make ivory tower decisions, and another to know the impact a decision
might have.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
Arthur wrote:
... But I still don't see the connection to XP programming, API design
Do you truly not understand my position, or merely disagree with it?
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http
in enumerate(farey_trials(partial(test_sqrt, 19, 1))):
if n -n == n: # report increasingly rarely
print n, fraction
if n 4096:
break
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig
for candidates, unless your fixed
point stuff reflects an underlying granularity.
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
:
yield a, b
--
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
(and all basic types).
Also, you didn't tweak hash, so a dictionary with these things in them
would not find entries that turn out to be equal.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org
Arthur wrote:
Scott David Daniels wrote:
...
Getting one's arms around all the practical implications of these issues
related to mutable, immutable - understanding when one should want to
retain object identity, and when one should want to break it, the full
implications
Beni Cherniavsky wrote:
On Mon, 2005-10-24 at 20:24 -0700, Scott David Daniels wrote:
Of course, the proper way to compare object identity is not the
__low_level__ `id()` function but the ``is`` operator:
(math.pi + 1.0) is (29. / 7.)
False
int('99') is int('99') # small integer
is not asking for free work -- only costed trade-offs are
available to choose from.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
. This path is a much more
abstract approach to the problem. I remember in the introduction to
the class (upon which this book was based), he claimed we call it
Concrete Mathematics because it is hard.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig
go at the same rate as the rest of TAoCP.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
.html
Hope this helps and is clear enough. Happy instructing.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
://portal.acm.org/tipsvc.cfm?id=1089734sess=%27%2BL%2F%2DP%5CK%2B30O%24%0A
If anyone else wants to grab a copy and chat about it after reading,
let me know.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org
of this work is:
http://www-epgy.stanford.edu/
I worked there back in the day and was quite proud to be a part of
some of that work.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo
, randomly pick a strand, and pick the
best question for that student in that strand. Or, you could bias the
choices between strands to give more balanced progress (increasing the
probability of work where the student is weakest).
--Scott David Daniels
[EMAIL PROTECTED
damon bryant wrote:
...
I have corrected the issue with the use of 'sum' (now ‘sum1’) and the
I'd suggest total would be a better replacement than sum1.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http
the primary aspect of
programming that the system attempts to simplify seems equally
troublesome, requiring a crystal ball -- I have no confidence in
reading this paper that another person would cut the boundaries
the same way.
--Scott David Daniels
[EMAIL PROTECTED
asking a question that is itself too round-about to have an
answer of the kind of am looking for? ;)
The above is as much as I can give you. You may get more from abstract
algebra people.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
.ncsu.edu/~rwchabay/mi
They teach both physics and enough programming to do 3-d programming
on the way to teaching physics. You might be able to make a short
course out of the how to program part of the books.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu
\idlelib\idle.pyw -n
Does this expedient not work for you?
The -n means to use a single-process model (more fragile,
but the interaction of two GUI loops is not there).
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
feel I got a much better idea of what, in
general, programming was from learning wildly disparate languages.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
interfacing with 3D (VPython) or actual
robot turtles (PYRO)
Obviously, these advance turtle environments would go through the
Cheeseshop, not the standard distribution.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig
as credit towards the purchase of the paper book
directly from them (which will be at full retail price).
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
Pen being how to control all of the dir() results.
--Scott David Daniels
[EMAIL PROTECTED]
# $Id: myrtle.py 1.3 2006/03/04 22:54:25 daniels Exp daniels $
'''Myrtle the minimally complex turtle'''
from math import sin, cos, tan, pi, atan2
import Tkinter
__version__ = '0.3'
__all__ = 'Turtle pi
when I was born. It was such a
wonderful surprise; a great conversation for both of us.
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
already
absorbed the OO paradigm, and were reimplementing it in C (to give us
C++, Java, C#) and in Python.
But many shared Smalltalk things involve mucking with the core objects:
This is my nifty whizz-bang: just add these methods to 'object' and
then you'll find that
-- Scott David
size from one that is guaranteed to settle might be a
disaster at the new-improved value.
So, that's why CS people like immutable primitive types.
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org
.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
is that immutable values can be safely
shared, a copy is never a meaningful operation on an immutable type.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
mutable
state on complexes (and then on points) -- the answer is when you are
applying a uniform transformation to a bunch of points.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman
Christian Mascher wrote:
Scott David Daniels wrote:
copying to a minimum. With immutables, you needn't do any of the
bookkeeping. It is not that you have gone terribly wrong; it is that
you have opened the lid on a large class of avoidable problems. If you
look at Java's strings (as I
of the discussion a number of people
slowly (or not so slowly) go away. That is what's to lose:
conversation with others.
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
to be able to prune the shell window
contents. Especially if you have output some long text w/o
returns in it, scrolling can get painfully slow as the output
accumulates.
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig
,
and had the most fun I've had in a new language in 30 years.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
is a living thing with lasers shining on it
(referring to it), that may shrivel up and die if it gets no light.
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
).
-- Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
guess we are all allowed to define sound programming for
ourselves.
With the exception you pointed out about space shuttles.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu
and Evolution of C++.
It will give you a nice skeleton around which to wrap your understanding
of C++, and help you understand how C++ came to be the way it is.
--Scott David Daniels
[EMAIL PROTECTED]
___
Edu-sig mailing list
Edu-sig@python.org
http
having to invest too much time)
Thanks for your time reading this message, and I welcome any
suggestion you may have.
Check in newsgroup fr.comp.lang.python. It is fairly active (nowhere
near comp.lang.python), but I'm certain there are resources.
--
-- Scott David Daniels
[EMAIL PROTECTED
kirby urner wrote:
Yutaka Nishiyama has this interesting article in the March 2006 issue
of Plus, entitled 'Mysterious number 6174'.
The theorem in this article is as follows: any 4-digit positive
integer, stipulating all 4 digits *not* be the same one, may be
distilled to 6174 by the following
, but at
the very least your students could download their installer themselves
for the economical price of $0.00.
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
out of tricks!
It is essential to have a Tcl/Tk development package installed before
configuring Python. I don't know enough about what packages you need
for Ubuntu, but check into it; that may be the problem (than make clean
./configure, )
--Scott David Daniels
scott.dani...@acm.org
carefully for legibility. The letters are larger now in absolute terms,
and _much_ larger in pixels, so I suffer with web pages and applications
that think they know what size text takes.
One size fits all is short for one size fits all that fit.
--Scott David Daniels
scott.dani...@acm.org
in check, check + 2:
for factor in factors:
if element % factor == 0:
break
else:
yield element
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig
Scott David Daniels wrote:
Scott David Daniels wrote:
I wrote:
In PythonOOP.doc (page 4) you say:
There are two pieces of magic that make line 3 work. First, the
interpreter has to find the method set_vars. It's not in cat2. Then,
the instance cat2 has to be inserted as the first
# self.area = width * height
@property
def area(self):
return self.width * self.height
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu
chunks. But Kirby and I
program about different things.
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
talking about the mechanics than about the idea. I suspect this is why
Kirby likes APL so much, he can easily express large-swath ideas. For
me, APL too quickly becomes terse little chunks. But Kirby and I
program about different things.
--Scott David Daniels
scott.dani...@acm.org
Yeah, plus
, or follow and extend it to enable unanticipated requirements.
Programs are (or should be) communications about the solution to
particular problems, not to the computer, but to future humans
reading the program.
--Scott David Daniels
scott.dani...@acm.org
last week with this little change was going to cost them a full
redevelop. These days I see this as matching the Agile Programming
goal of leaving the customer in charge, but then I just thought it was
a miraculous way of explaining explaining what the extra time went for.
--Scott David Daniels
if they really worked. Students need to
know that not everything has been done.
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
and
Programming in Python, a Multimedia Approach, Prentice Hall, 2005.
This change was so successful that, second courses for both engineering
and media are now in place (the demand was high), and they've introduced
a CS minor.
--Scott David Daniels
scott.dani...@acm.org
):
return args
Funny[1, ..., 10]
(1, Ellipsis, 3)
Ellipsis
Ellipsis
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
Scott David Daniels wrote:
kirby urner wrote:
... Hey, did you know Ellipsis is a new primitive object ...
Actually, it has been around for quite a while [broken example]
Sorry, everybody, I started writing, tried the code, and editted the
reply, rather than taking direct quotes
release (think if 3.0 as a Python 3000
alpha or beta).
--Scott David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
David Daniels
scott.dani...@acm.org
___
Edu-sig mailing list
Edu-sig@python.org
http://mail.python.org/mailman/listinfo/edu-sig
80 matches
Mail list logo