PyObjC with Xcode 3.0 Leopard

2007-11-04 Thread flyfree
I got an error during making a python application with xcode 3.0 in OS
X Leopard.

(KeyError: 'NSUnknownKeyException - [
valueForUndefinedKey:]: this class is not key value coding-compliant
for the key calculatedMean.')

The application is a simple example of how to use the PyObjC with
xcode 2.0.
http://developer.apple.com/cocoa/pyobjc.html

Could you give any hint to start to dig into it?

-- 
http://mail.python.org/mailman/listinfo/python-list


Changing argument value

2007-12-13 Thread flyfree
>>> def fooA(y):
y = [3,4]
return y

>>> def fooB(y):
y[0] = 3
y[1] = 4
return y

>>> x = [1,2]
>>> fooA(x)
[3, 4]
>>> x
[1, 2]

>>> fooB(x)
[3, 4]
>>> x
[3, 4]
===

>From above, the original argument value of fooA is same as before
[1,2]
but the original argument value of fooB is changed from [1,2] to
[3,4].

What is the difference between "y = [3,4]" and "y[0]=3
 
y[1] =4 "


Thanks,

SC
-- 
http://mail.python.org/mailman/listinfo/python-list