Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #7259

Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE

Path csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!news-out.readnews.com!transit3.readnews.com!panix!gordon
From John Gordon <gordon@panix.com>
Newsgroups comp.lang.python
Subject Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE
Date Wed, 8 Jun 2011 20:42:24 +0000 (UTC)
Organization PANIX Public Access Internet and UNIX, NYC
Lines 19
Message-ID <isomrg$b3g$1@reader1.panix.com> (permalink)
References <mailman.30.1307563778.11593.python-list@python.org>
NNTP-Posting-Host panix2.panix.com
X-Trace reader1.panix.com 1307565744 11376 166.84.1.2 (8 Jun 2011 20:42:24 GMT)
X-Complaints-To abuse@panix.com
NNTP-Posting-Date Wed, 8 Jun 2011 20:42:24 +0000 (UTC)
User-Agent nn/6.7.3
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:7259

Show key headers only | View raw


In <mailman.30.1307563778.11593.python-list@python.org> Cathy James <nambo4jb@gmail.com> writes:

> b) I would like to append to my list, but my line dogs.dogAppend() is
> giving a TypeError:

> for i in enumerate (self.dogAppend()):
> TypeError: 'list' object is not callable

>     def dogAppend(self):
>         self.dogAppend = []

You have a method and a list that are both called dogAppend.  Try naming
one of them something different.

-- 
John Gordon                   A is for Amy, who fell down the stairs
gordon@panix.com              B is for Basil, assaulted by bears
                                -- Edward Gorey, "The Gashlycrumb Tinies"

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Of Functions, Objects, and Methods-I NEED HELP PLEASE Cathy James <nambo4jb@gmail.com> - 2011-06-08 15:09 -0500
  Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE John Gordon <gordon@panix.com> - 2011-06-08 20:42 +0000
  Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE Larry Hudson <orgnut@yahoo.com> - 2011-06-08 23:59 -0700
    Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE Ethan Furman <ethan@stoneleaf.us> - 2011-06-09 05:54 -0700
    Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE Ethan Furman <ethan@stoneleaf.us> - 2011-06-09 06:10 -0700
    Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2011-06-09 10:25 -0700
    Re: Of Functions, Objects, and Methods-I NEED HELP PLEASE Larry Hudson <orgnut@yahoo.com> - 2011-06-09 23:07 -0700

csiph-web