Path: csiph.com!news.fcku.it!bofh.it!tornado.fastwebnet.it!53ab2750!not-for-mail Newsgroups: it.comp.lang.python X-Mozilla-News-Host: news://news.fastwebnet.it:119 From: Smith Subject: Classi User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15; format=flowed Content-Transfer-Encoding: 8bit Lines: 22 Message-ID: <47Kgz.47242$pt.15731@tornado.fastwebnet.it> Date: Mon, 11 Jul 2016 12:00:34 +0200 NNTP-Posting-Host: 2.235.183.179 X-Complaints-To: newsmaster@fastweb.it X-Trace: tornado.fastwebnet.it 1468231232 2.235.183.179 (Mon, 11 Jul 2016 12:00:32 CEST) NNTP-Posting-Date: Mon, 11 Jul 2016 12:00:32 CEST Xref: csiph.com it.comp.lang.python:7674 Ciao a tutti, perchè questo script mi restituisce il messaggio d'errore: AttributeError: 'NoneType' object has no attribute 'moo' Mentre dovrei ottenere : 'python3.4' Mi potete aiutare? Grazie def foo(): a = 'python3.4' class Foo: def moo(): print(a) return Foo F = foo() F.moo()